fix: reload user preferences after signing in
This commit is contained in:
@@ -58,15 +58,15 @@ export class PreferencesManager extends ApplicationService {
|
|||||||
this.userPreferences = (await this.application!.singletonManager!.findOrCreateSingleton(
|
this.userPreferences = (await this.application!.singletonManager!.findOrCreateSingleton(
|
||||||
predicate,
|
predicate,
|
||||||
contentType,
|
contentType,
|
||||||
FillItemContent({}),
|
FillItemContent({})
|
||||||
)) as SNUserPrefs;
|
)) as SNUserPrefs;
|
||||||
this.loadingPrefs = false;
|
this.loadingPrefs = false;
|
||||||
this.needsSingletonReload = false;
|
this.needsSingletonReload = false;
|
||||||
const didChange =
|
if (
|
||||||
!previousRef ||
|
previousRef?.uuid !== this.userPreferences.uuid ||
|
||||||
this.userPreferences.lastSyncBegan?.getTime() !==
|
this.userPreferences.lastSyncBegan?.getTime() !==
|
||||||
previousRef?.lastSyncBegan?.getTime();
|
previousRef?.lastSyncBegan?.getTime()
|
||||||
if (didChange) {
|
) {
|
||||||
this.webApplication
|
this.webApplication
|
||||||
.getAppState()
|
.getAppState()
|
||||||
.setUserPreferences(this.userPreferences);
|
.setUserPreferences(this.userPreferences);
|
||||||
|
|||||||
Reference in New Issue
Block a user