From 9d9504e57c477a02c50041d36f093c38c6386038 Mon Sep 17 00:00:00 2001 From: Marcos Date: Thu, 18 Jul 2024 18:07:36 -0300 Subject: [PATCH] chore: Added extra comments on the useDecision() usage --- src/experiments/experimentHooks.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/experiments/experimentHooks.js b/src/experiments/experimentHooks.js index 1d9c33c5..ec15a339 100644 --- a/src/experiments/experimentHooks.js +++ b/src/experiments/experimentHooks.js @@ -9,8 +9,8 @@ export function usePromptExperimentDecision() { const [decision] = useDecision( OPTIMIZELY_PROMPT_EXPERIMENT_KEY, - { autoUpdate: true }, - { overrideUserId: userId.toString() }, + { autoUpdate: true }, // This should make the decision reactive to changes on the experiment dashboard. + { overrideUserId: userId.toString() }, // This override is just to make sure the userId is up to date. ); return [decision];