We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 97d29f8 commit 494a089Copy full SHA for 494a089
1 file changed
app/src/lib/stores/app-store.ts
@@ -5281,10 +5281,9 @@ export class AppStore extends TypedBaseStore<IAppState> {
5281
// we need to switch to a different branch (default or recent).
5282
const branchToCheckout =
5283
toCheckout ?? this.getBranchToCheckoutAfterDelete(branch, repository)
5284
- const deletingMainBranch =
5285
- branchToCheckout === null || branchToCheckout.ref === branch.ref
5286
-
5287
- if (deletingMainBranch) {
+ if (branchToCheckout === null) {
+ // No checkout needed
+ } else if (branchToCheckout.ref === branch.ref) {
5288
this._showPopup({
5289
type: PopupType.CantDeleteMainBranch,
5290
repository,
0 commit comments