Observe CRT preference with values (#6291)

This commit is contained in:
Daniel Espino García 2022-05-19 12:32:06 +02:00 committed by GitHub
parent 0464dd34ee
commit 4bd2416d47
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -36,7 +36,7 @@ export const getThreadById = async (database: Database, threadId: string) => {
export const observeIsCRTEnabled = (database: Database) => {
const config = observeConfig(database);
const preferences = queryPreferencesByCategoryAndName(database, Preferences.CATEGORY_DISPLAY_SETTINGS).observe();
const preferences = queryPreferencesByCategoryAndName(database, Preferences.CATEGORY_DISPLAY_SETTINGS).observeWithColumns(['value']);
return combineLatest([config, preferences]).pipe(
map(
([cfg, prefs]) => isCRTEnabled(prefs, cfg),