mirror of
https://github.com/bitwarden/browser
synced 2025-12-10 21:33:27 +00:00
Removes clobbering emission of empty array. (#16682)
* Removes clobbering emission of empty array. * Additional 'startWith' removal.
This commit is contained in:
@@ -120,7 +120,7 @@ export class VaultPopupItemsService {
|
|||||||
.cipherListViews$(userId)
|
.cipherListViews$(userId)
|
||||||
.pipe(filter((ciphers) => ciphers != null)),
|
.pipe(filter((ciphers) => ciphers != null)),
|
||||||
this.cipherService.failedToDecryptCiphers$(userId),
|
this.cipherService.failedToDecryptCiphers$(userId),
|
||||||
this.restrictedItemTypesService.restricted$.pipe(startWith([])),
|
this.restrictedItemTypesService.restricted$,
|
||||||
]),
|
]),
|
||||||
),
|
),
|
||||||
map(([ciphers, failedToDecryptCiphers, restrictions]) => {
|
map(([ciphers, failedToDecryptCiphers, restrictions]) => {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
// FIXME: Update this file to be type safe and remove this and next line
|
// FIXME: Update this file to be type safe and remove this and next line
|
||||||
// @ts-strict-ignore
|
// @ts-strict-ignore
|
||||||
import { combineLatest, map, Observable, startWith, switchMap } from "rxjs";
|
import { combineLatest, map, Observable, switchMap } from "rxjs";
|
||||||
|
|
||||||
import { CipherType } from "@bitwarden/common/vault/enums";
|
import { CipherType } from "@bitwarden/common/vault/enums";
|
||||||
import { RestrictedItemTypesService } from "@bitwarden/common/vault/services/restricted-item-types.service";
|
import { RestrictedItemTypesService } from "@bitwarden/common/vault/services/restricted-item-types.service";
|
||||||
@@ -205,7 +205,7 @@ export class AutofillSettingsService implements AutofillSettingsServiceAbstracti
|
|||||||
this.showInlineMenuCardsState = this.stateProvider.getActive(SHOW_INLINE_MENU_CARDS);
|
this.showInlineMenuCardsState = this.stateProvider.getActive(SHOW_INLINE_MENU_CARDS);
|
||||||
this.showInlineMenuCards$ = combineLatest([
|
this.showInlineMenuCards$ = combineLatest([
|
||||||
this.showInlineMenuCardsState.state$.pipe(map((x) => x ?? true)),
|
this.showInlineMenuCardsState.state$.pipe(map((x) => x ?? true)),
|
||||||
this.restrictedItemTypesService.restricted$.pipe(startWith([])),
|
this.restrictedItemTypesService.restricted$,
|
||||||
]).pipe(
|
]).pipe(
|
||||||
map(
|
map(
|
||||||
([enabled, restrictions]) =>
|
([enabled, restrictions]) =>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { Observable, combineLatest, map, shareReplay, startWith } from "rxjs";
|
import { Observable, combineLatest, map, shareReplay } from "rxjs";
|
||||||
|
|
||||||
import { ActiveUserState, GlobalState, StateProvider } from "../../../platform/state";
|
import { ActiveUserState, GlobalState, StateProvider } from "../../../platform/state";
|
||||||
import { VaultSettingsService as VaultSettingsServiceAbstraction } from "../../abstractions/vault-settings/vault-settings.service";
|
import { VaultSettingsService as VaultSettingsServiceAbstraction } from "../../abstractions/vault-settings/vault-settings.service";
|
||||||
@@ -31,7 +31,7 @@ export class VaultSettingsService implements VaultSettingsServiceAbstraction {
|
|||||||
*/
|
*/
|
||||||
readonly showCardsCurrentTab$: Observable<boolean> = combineLatest([
|
readonly showCardsCurrentTab$: Observable<boolean> = combineLatest([
|
||||||
this.showCardsCurrentTabState.state$.pipe(map((x) => x ?? true)),
|
this.showCardsCurrentTabState.state$.pipe(map((x) => x ?? true)),
|
||||||
this.restrictedItemTypesService.restricted$.pipe(startWith([])),
|
this.restrictedItemTypesService.restricted$,
|
||||||
]).pipe(
|
]).pipe(
|
||||||
map(
|
map(
|
||||||
([enabled, restrictions]) =>
|
([enabled, restrictions]) =>
|
||||||
|
|||||||
Reference in New Issue
Block a user