Skip to content

fix(integrations): persist connection status on tab re-visit + guard GitHub close issue#51

Merged
neethika12 merged 2 commits into
mainfrom
feature/decision-delete-modal
Apr 29, 2026
Merged

fix(integrations): persist connection status on tab re-visit + guard GitHub close issue#51
neethika12 merged 2 commits into
mainfrom
feature/decision-delete-modal

Conversation

@neethika12
Copy link
Copy Markdown
Contributor

Summary

Fixes two bugs (Sentinent-AI/Sentinent#35) and includes the decision delete modal.

Changes

feat: Custom delete modal for decisions

Replaces the native confirm() dialog with a polished UI modal that matches the existing workspace delete modal design — backdrop fade, slide-up card, loading state, error handling, and double-click guard.

fix: Connection status persists when navigating away from integrations tab

getSlackChannels and getGitHubRepos were chaining a live API call after the DB record lookup. If that call failed (rate limit, token expiry, network hiccup), the entire observable threw and the UI flipped back to "disconnected". Fixed by building a baseState with connected: true from the DB record first, then using an inner catchError(() => of(baseState)) so API failures degrade gracefully to connected with empty list instead of disconnected.

fix: Guard against missing workspaceId when closing/commenting on GitHub issues

toggleGitHubState and addGitHubComment in signal-board.ts were calling the API even when workspaceId was empty, producing silent 400 errors with no user feedback. Added an explicit guard that returns early and shows a descriptive toast.

fix: Corrected double path segment in replyToSlack

/api/integrations/integrations/slack/reply/api/integrations/slack/reply

Files changed

  • src/app/components/decision-list/decision-list.component.ts
  • src/app/components/decision-list/decision-list.component.html
  • src/app/components/decision-list/decision-list.component.css
  • src/app/components/decision-list/decision-list.component.spec.ts
  • src/app/services/integration.service.ts
  • src/app/components/signal-board/signal-board.ts

…d GitHub close issue

- getSlackChannels: build baseState from DB record first; catch inner API errors
  so Slack 'connected' flag no longer flips to false when channels endpoint is
  temporarily unreachable
- getGitHubRepos: same pattern — baseState from DB record, inner catchError falls
  back to connected:true with empty repo list instead of re-throwing
- Fix double-slash URL in replyToSlack (/api/integrations/integrations/slack/reply
  → /api/integrations/slack/reply)
- signal-board: guard toggleGitHubState and addGitHubComment against missing
  workspaceId; surface actionable toast instead of silent 400

Fixes Sentinent-AI/Sentinent#35
@neethika12 neethika12 merged commit 15e05ce into main Apr 29, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant