Fixed ctrl+enter not amending if there are no staged changes

This commit is contained in:
Abdelilah El Aissaoui 2023-04-19 23:01:19 +02:00
parent 29c04dbad3
commit 4d32df5717
No known key found for this signature in database
GPG Key ID: 7587FC860F594869

View File

@ -201,7 +201,7 @@ fun UncommitedChanges(
.fillMaxWidth()
.weight(weight = 1f, fill = true)
.onPreviewKeyEvent { keyEvent ->
if (keyEvent.matchesBinding(KeybindingOption.TEXT_ACCEPT) && canCommit) {
if (keyEvent.matchesBinding(KeybindingOption.TEXT_ACCEPT) && (canCommit || isAmend && canAmend)) {
doCommit()
true
} else