Mercurial > hg
changeset 47480:f93298a48da1
dirstate: split a not-so-one-liner
This is simpler to read.
Differential Revision: https://phab.mercurial-scm.org/D10924
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Thu, 01 Jul 2021 18:57:35 +0200 |
parents | e6b303eb8f7d |
children | 612f5f36fcf6 |
files | mercurial/dirstate.py |
diffstat | 1 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/dirstate.py Thu Jul 01 18:56:34 2021 +0200 +++ b/mercurial/dirstate.py Thu Jul 01 18:57:35 2021 +0200 @@ -433,9 +433,9 @@ if state == b'a' or oldstate == b'r': scmutil.checkfilename(f) if self._map.hastrackeddir(f): - raise error.Abort( - _(b'directory %r already in dirstate') % pycompat.bytestr(f) - ) + msg = _(b'directory %r already in dirstate') + msg %= pycompat.bytestr(f) + raise error.Abort(msg) # shadows for d in pathutil.finddirs(f): if self._map.hastrackeddir(d):