diff hgext/censor.py @ 48130:5105a9975407

errors: raise InputError from revsingle() iff revset provided by the user Same reasoning as for `revrange()` in an earlier patch. Differential Revision: https://phab.mercurial-scm.org/D11562
author Martin von Zweigbergk <martinvonz@google.com>
date Tue, 28 Sep 2021 15:11:22 -0700
parents bec734015b70
children 6000f5b25c9b
line wrap: on
line diff
--- a/hgext/censor.py	Tue Sep 28 13:59:01 2021 -0700
+++ b/hgext/censor.py	Tue Sep 28 15:11:22 2021 -0700
@@ -35,6 +35,7 @@
 
 from mercurial import (
     error,
+    logcmdutil,
     registrar,
     scmutil,
 )
@@ -84,7 +85,7 @@
     if not len(flog):
         raise error.Abort(_(b'cannot censor file with no history'))
 
-    rev = scmutil.revsingle(repo, rev, rev).rev()
+    rev = logcmdutil.revsingle(repo, rev, rev).rev()
     try:
         ctx = repo[rev]
     except KeyError: