Skip to content

Commit

Permalink
resolved the review cmts
Browse files Browse the repository at this point in the history
  • Loading branch information
Yagnik56 committed Jun 15, 2024
1 parent 62bcdef commit 17b6000
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export class FeatureFlagsService {
isSelectedFeatureFlagRemoved$ = this.store$.pipe(
select(selectSelectedFeatureFlag),
pairwise(),
filter(([prev, curr]) => prev !== null && prev !== undefined && (curr === null || curr === undefined))
filter(([prev, curr]) => prev && !curr)
);

selectedFlagOverviewDetails = this.store$.pipe(select(selectFeatureFlagOverviewDetails));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,15 +62,14 @@ export class DeleteFeatureFlagModalComponent {
) {}

ngOnInit(): void {
this.listenForFeatureFlagListLengthChanges();
this.listenForSelectedFeatureFlagDeletion();
}

onInputChange(value: string): void {
this.inputSubject.next(value);
}

// Close the modal once the feature flag list length changes, as that indicates actual success
listenForFeatureFlagListLengthChanges(): void {
listenForSelectedFeatureFlagDeletion(): void {
this.subscriptions = this.isSelectedFeatureFlagRemoved$.subscribe(() => this.closeModal());
}

Expand Down

0 comments on commit 17b6000

Please sign in to comment.