From aab226cf146c80f8d5acf6dc6284e89834258be1 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Gustav=20H=C3=A5llberg?= Date: Fri, 4 Dec 2009 08:55:02 +0100 Subject: [PATCH] new: Allow empty messages with --message and --file MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Gustav HÃ¥llberg --- stgit/commands/common.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stgit/commands/common.py b/stgit/commands/common.py index ac53654..2c525ba 100644 --- a/stgit/commands/common.py +++ b/stgit/commands/common.py @@ -470,7 +470,7 @@ def update_commit_data(cd, options): """Return a new CommitData object updated according to the command line options.""" # Set the commit message from commandline. - if options.message != None: + if options.message is not None: cd = cd.set_message(options.message) # Modify author data. @@ -488,7 +488,7 @@ def update_commit_data(cd, options): # Let user edit the commit message manually, unless # --save-template or --message was specified. - if not getattr(options, 'save_template', None) and not options.message: + if not getattr(options, 'save_template', None) and options.message is None: cd = cd.set_message(edit_string(cd.message, '.stgit-new.txt')) return cd -- 2.11.0