next: use the `hint` argument of bail if changed
authorPierre-Yves David <pierre-yves.david@octobus.net>
Sat, 10 Nov 2018 16:01:31 +0100
changeset 4239 7e274734cc2c
parent 4238 18648e1aded0
child 4240 323b3dac5bba
next: use the `hint` argument of bail if changed The argument is availabel since Mercurial 4.1. So let's use it.
hgext3rd/evolve/__init__.py
--- a/hgext3rd/evolve/__init__.py	Sat Nov 10 15:59:16 2018 +0100
+++ b/hgext3rd/evolve/__init__.py	Sat Nov 10 16:01:31 2018 +0100
@@ -1154,11 +1154,7 @@
             if ui.config('commands', 'update.check') == 'noconflict':
                 pass
             else:
-                try:
-                    cmdutil.bailifchanged(repo)
-                except error.Abort as exc:
-                    exc.hint = _('do you want --merge?')
-                    raise
+                cmdutil.bailifchanged(repo, hint=_('do you want --merge?'))
 
         if len(children) == 1:
             c = children[0]