Update subproject commit and refactor OAuth connection handling in SkillSetupWizard

- Updated the subproject commit reference in the skills directory.
- Refactored the SkillSetupWizard component to use `connection_status: "connected"` instead of `connected: true` for improved clarity in state management during OAuth completion.
This commit is contained in:
Steven Enamakel
2026-02-09 09:24:48 +05:30
parent 49648606a4
commit 6ad553f16e
2 changed files with 5 additions and 4 deletions
+1 -1
Submodule skills updated: 1d26ee8947...2275afb466
+4 -3
View File
@@ -43,21 +43,22 @@ export default function SkillSetupWizard({
}: SkillSetupWizardProps) {
const [state, setState] = useState<WizardState>({ phase: "loading" });
// Watch skill state for OAuth completion (skill pushes connected: true)
// Watch skill state for OAuth completion (skill pushes connection_status: "connected")
const skillState = useAppSelector(
(s) => s.skills.skillStates[skillId],
);
const isConnected = skillState?.connection_status === "connected";
// When skill state changes to connected during OAuth waiting, mark complete
useEffect(() => {
if (
(state.phase === "oauth" || state.phase === "oauth_waiting") &&
skillState?.connected === true
isConnected
) {
store.dispatch(setSkillSetupComplete({ skillId, complete: true }));
setState({ phase: "complete", message: "Successfully connected!" });
}
}, [skillState?.connected, state.phase, skillId]);
}, [isConnected, state.phase, skillId]);
// Start the skill (if not running) then start the setup flow on mount
useEffect(() => {