Fix new link scenario where default color is not set

This commit is contained in:
Josh Perez 2021-06-07 18:17:44 -04:00 committed by GitHub
parent 906b949c47
commit d38a0042ba
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 9 deletions

View file

@ -81,6 +81,14 @@ export async function startApp(): Promise<void> {
ourProfileKeyService.initialize(window.storage);
window.storage.onready(() => {
if (!window.storage.get('defaultConversationColor')) {
window.storage.put('defaultConversationColor', {
color: 'ultramarine',
});
}
});
let resolveOnAppView: (() => void) | undefined;
const onAppView = new Promise<void>(resolve => {
resolveOnAppView = resolve;
@ -414,12 +422,6 @@ export async function startApp(): Promise<void> {
}
first = false;
if (!window.storage.get('defaultConversationColor')) {
window.storage.put('defaultConversationColor', {
color: 'ultramarine',
});
}
cleanupSessionResets();
const retryPlaceholders = new window.Signal.Util.RetryPlaceholders();
window.Signal.Services.retryPlaceholders = retryPlaceholders;