mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
git4idea: IDEA-53782: empty commit message is handled more gracefully
This commit is contained in:
@@ -170,6 +170,11 @@ public class GitCheckinEnvironment implements CheckinEnvironment {
|
||||
*/
|
||||
public List<VcsException> commit(@NotNull List<Change> changes, @NotNull String message) {
|
||||
List<VcsException> exceptions = new ArrayList<VcsException>();
|
||||
if (message.length() == 0) {
|
||||
//noinspection ThrowableInstanceNeverThrown
|
||||
exceptions.add(new VcsException("Empty commit message is not supported for the Git"));
|
||||
return exceptions;
|
||||
}
|
||||
Map<VirtualFile, List<Change>> sortedChanges = sortChangesByGitRoot(changes, exceptions);
|
||||
if (GitConvertFilesDialog.showDialogIfNeeded(myProject, mySettings, sortedChanges, exceptions)) {
|
||||
for (Map.Entry<VirtualFile, List<Change>> entry : sortedChanges.entrySet()) {
|
||||
|
||||
Reference in New Issue
Block a user