Skip to content

Commit

Permalink
fix: react to feature_enabled changes (#148)
Browse files Browse the repository at this point in the history
* test: fix variant result assumption

* fix: react to feature_enabled changes
  • Loading branch information
nunogois authored Nov 9, 2023
1 parent 9a52852 commit a576115
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/useVariant.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ export const variantHasChanged = (
const variantsAreEqual =
oldVariant.name === newVariant?.name &&
oldVariant.enabled === newVariant?.enabled &&
oldVariant.feature_enabled === newVariant?.feature_enabled &&
oldVariant.payload?.type === newVariant?.payload?.type &&
oldVariant.payload?.value === newVariant?.payload?.value;

Expand Down

0 comments on commit a576115

Please sign in to comment.