changeset 24476:1378f20c8564

record: change return value of recording code It makes it easier to include interactive mode to more commands that require to get a reference to the newly created node
author Laurent Charignon <lcharignon@fb.com>
date Wed, 25 Mar 2015 15:51:57 -0700
parents 06cbff4674a3
children 325f03de849d
files mercurial/cmdutil.py
diffstat 1 files changed, 1 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/cmdutil.py	Wed Mar 25 14:01:14 2015 -0700
+++ b/mercurial/cmdutil.py	Wed Mar 25 15:51:57 2015 -0700
@@ -186,9 +186,7 @@
 
             # Make all of the pathnames absolute.
             newfiles = [repo.wjoin(nf) for nf in newfiles]
-            commitfunc(ui, repo, *newfiles, **opts)
-
-            return 0
+            return commitfunc(ui, repo, *newfiles, **opts)
         finally:
             # 5. finally restore backed-up files
             try: