Skip to content

Fix connecting error after connection cancel#1174

Merged
1Blademaster merged 1 commit into
mainfrom
1173-bug-drone-in-connection-error-after-cancelling-connection
Apr 20, 2026
Merged

Fix connecting error after connection cancel#1174
1Blademaster merged 1 commit into
mainfrom
1173-bug-drone-in-connection-error-after-cancelling-connection

Conversation

@1Blademaster
Copy link
Copy Markdown
Member

No description provided.

Copilot AI review requested due to automatic review settings April 20, 2026 19:11
@1Blademaster 1Blademaster linked an issue Apr 20, 2026 that may be closed by this pull request
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adjusts the connection modal close/cancel behavior in the GCS navbar to avoid triggering connection-state issues when a user cancels an in-progress connection attempt.

Changes:

  • Centralized modal close/cancel logic into handleConnectionModalCloseOrCancel.
  • When connecting is true, close/cancel now dispatches emitDisconnectFromDrone() (which maps to cancel_connect_to_drone) without immediately forcing connecting/modal state changes.
  • Reused the shared handler for both the Mantine Modal onClose and the “Cancel/Close” button.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@1Blademaster 1Blademaster merged commit 0ae980a into main Apr 20, 2026
9 checks passed
@1Blademaster 1Blademaster deleted the 1173-bug-drone-in-connection-error-after-cancelling-connection branch April 20, 2026 19:21
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.

[BUG] Drone in connection error after cancelling connection

2 participants