Fix new link scenario where default color is not set
This commit is contained in:
parent
906b949c47
commit
d38a0042ba
2 changed files with 11 additions and 9 deletions
|
@ -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;
|
||||
|
|
|
@ -1865,9 +1865,9 @@ describe('both/state/selectors/conversations', () => {
|
|||
assert.equal(contactNameColorSelector('group', 'jih'), '120');
|
||||
assert.equal(contactNameColorSelector('group', 'mlk'), '300');
|
||||
assert.equal(contactNameColorSelector('group', 'pon'), '010');
|
||||
assert.equal(contactNameColorSelector('group', 'srq'), '330');
|
||||
assert.equal(contactNameColorSelector('group', 'vut'), '230');
|
||||
assert.equal(contactNameColorSelector('group', 'zyx'), '180');
|
||||
assert.equal(contactNameColorSelector('group', 'srq'), '210');
|
||||
assert.equal(contactNameColorSelector('group', 'vut'), '330');
|
||||
assert.equal(contactNameColorSelector('group', 'zyx'), '230');
|
||||
});
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue