fix: Improve error handling and state management in auto-mode and utilities

This commit is contained in:
gsxdsm
2026-02-18 23:12:11 -08:00
parent a144a63c51
commit be4153c374
4 changed files with 32 additions and 22 deletions

View File

@@ -112,6 +112,9 @@ export function CreateBranchDialog({
if (open) {
setBranchName('');
setBaseBranch('');
// Update the ref synchronously so fetchBranches() sees the cleared value
// immediately, rather than the stale value from the previous open.
baseBranchRef.current = '';
setError(null);
setBranches([]);
setBaseBranchPopoverOpen(false);