From d94847d8e170c57e42aea039de182c998ec84cd5 Mon Sep 17 00:00:00 2001 From: Rodrigo Santana Date: Fri, 16 Feb 2024 16:06:02 -0300 Subject: [PATCH] Fix inconsistent reflog entry format by adding the commit message --- js/controlbox.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/js/controlbox.js b/js/controlbox.js index c9761bf..8af7ecf 100644 --- a/js/controlbox.js +++ b/js/controlbox.js @@ -372,7 +372,6 @@ function(_yargs, d3, demos) { boolean: ['amend'], string: ['m'] }) - var msg = "" this.transact(function() { if (opts.amend) { this.getRepoView().amendCommit(opts.m || this.getRepoView().getCommit('head').message) @@ -380,7 +379,7 @@ function(_yargs, d3, demos) { this.getRepoView().commit(null, opts.m); } }, function(before, after) { - var reflogMsg = 'commit: ' + msg + var reflogMsg = 'commit: ' + (after.commit.message ?? ''); this.getRepoView().addReflogEntry( 'HEAD', after.commit.id, reflogMsg )