diff --git a/mercurial/debugcommands.py b/mercurial/debugcommands.py
index 6915f6a4028363a0f8a64f93e088fd5189d6cd0c_bWVyY3VyaWFsL2RlYnVnY29tbWFuZHMucHk=..3bb1a647ab42ff71f40793118aae547e721d64d0_bWVyY3VyaWFsL2RlYnVnY29tbWFuZHMucHk= 100644
--- a/mercurial/debugcommands.py
+++ b/mercurial/debugcommands.py
@@ -2307,10 +2307,6 @@
     cache = {}
     ctx2str = str
     node2str = short
-    if ui.debug():
-        def ctx2str(ctx):
-            return ctx.hex()
-        node2str = hex
     for rev in scmutil.revrange(repo, revs):
         ctx = repo[rev]
         ui.write('%s\n'% ctx2str(ctx))