From patchwork Mon Oct 14 17:10:21 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: D7086: fix: remove a never-true check for unset pattern in Fixer.affects() From: phabricator X-Patchwork-Id: 42327 Message-Id: <3bf19c59117ae8d8044a1c1ec1a9d5e5@localhost.localdomain> To: Phabricator Cc: mercurial-devel@mercurial-scm.org Date: Mon, 14 Oct 2019 17:10:21 +0000 Closed by commit rHG96c4c6f37d52: fix: remove a never-true check for unset pattern in Fixer.affects() (authored by martinvonz). This revision was automatically updated to reflect the committed changes. REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D7086?vs=17131&id=17144 CHANGES SINCE LAST ACTION https://phab.mercurial-scm.org/D7086/new/ REVISION DETAIL https://phab.mercurial-scm.org/D7086 AFFECTED FILES hgext/fix.py CHANGE DETAILS To: martinvonz, #hg-reviewers, pulkit Cc: hooper, mercurial-devel diff --git a/hgext/fix.py b/hgext/fix.py --- a/hgext/fix.py +++ b/hgext/fix.py @@ -845,9 +845,7 @@ def affects(self, opts, fixctx, path): """Should this fixer run on the file at the given path and context?""" - return self._pattern is not None and scmutil.match( - fixctx, [self._pattern], opts - )(path) + return scmutil.match(fixctx, [self._pattern], opts)(path) def shouldoutputmetadata(self): """Should the stdout of this fixer start with JSON and a null byte?"""