Skip to content

Commit

Permalink
Fixing projectId state by ordering state change (#6437)
Browse files Browse the repository at this point in the history
Co-authored-by: Patrick Volum <[email protected]>
  • Loading branch information
2 people authored and boydc2014 committed Mar 17, 2021
1 parent ffda715 commit 830559e
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -704,8 +704,6 @@ export const postRootBotCreation = async (
source,
projectIdCache
) => {
callbackHelpers.set(botProjectIdsState, (current) => [...current, projectId]);

if (settingStorage.get(projectId)) {
settingStorage.remove(projectId);
}
Expand All @@ -719,6 +717,9 @@ export const postRootBotCreation = async (
callbackHelpers.set(createQnAOnState, { projectId, dialogId: mainDialog });
callbackHelpers.set(showCreateQnAFromUrlDialogState(projectId), true);
}

callbackHelpers.set(botProjectIdsState, [projectId]);

if (profile) {
// ABS Create Flow, update publishProfile after create project
const dispatcher = await callbackHelpers.snapshot.getPromise(dispatcherState);
Expand Down

0 comments on commit 830559e

Please sign in to comment.