Skip to content

Commit

Permalink
fix(header): link filtering
Browse files Browse the repository at this point in the history
  • Loading branch information
cecilia-sanare committed Jan 20, 2024
1 parent e16f0b0 commit 58b2448
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 1 addition & 4 deletions backend/services/environment.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,7 @@ const FEATURE_FLAGS: Record<FeatureFlag, FeatureFlagValue> = {
[Environment.Local]: true,
[Environment.Alpha]: true,
},
[FeatureFlag.Characters]: {
[Environment.Local]: true,
[Environment.Alpha]: true,
},
[FeatureFlag.Characters]: true,
};

export const ENVIRONMENT: Environment =
Expand Down
2 changes: 1 addition & 1 deletion components/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ const links: Header.Link[] = (
flag: FeatureFlag.Characters,
},
] satisfies Header.Link[]
).filter((link) => !link.flag || EnvironmentService.enabled(link.flag));
).filter((link) => typeof link.flag === 'undefined' || EnvironmentService.enabled(link.flag));

export function Header() {
const pathname = usePathname();
Expand Down

0 comments on commit 58b2448

Please sign in to comment.