Patchwork D1978: narrow: assume addflagprocessor will always exist on revlog module

login
register
mail settings
Submitter phabricator
Date Feb. 1, 2018, 11 p.m.
Message ID <differential-rev-PHID-DREV-3rtpp5y3vva2g6ssr26q-req@phab.mercurial-scm.org>
Download mbox | patch
Permalink /patch/27167/
State Superseded
Headers show

Comments

phabricator - Feb. 1, 2018, 11 p.m.
durin42 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D1978

AFFECTED FILES
  hgext/narrow/narrowrevlog.py

CHANGE DETAILS




To: durin42, #hg-reviewers
Cc: mercurial-devel

Patch

diff --git a/hgext/narrow/narrowrevlog.py b/hgext/narrow/narrowrevlog.py
--- a/hgext/narrow/narrowrevlog.py
+++ b/hgext/narrow/narrowrevlog.py
@@ -27,9 +27,8 @@ 
 def rawtransform(self, text):
     return False
 
-if util.safehasattr(revlog, 'addflagprocessor'):
-    revlog.addflagprocessor(ELLIPSIS_NODE_FLAG,
-                            (readtransform, writetransform, rawtransform))
+revlog.addflagprocessor(ELLIPSIS_NODE_FLAG,
+                        (readtransform, writetransform, rawtransform))
 
 def setup():
     # We just wanted to add the flag processor, which is done at module