Do not inspect node1 for diff if node2 is given
authorChristian Ebert <blacktrash@gmx.net>
Thu, 14 Feb 2008 16:11:54 +0100
changeset 410 64cd77f6f7f1
parent 409 6e2293f7b9f7
child 413 1b6610abf538
Do not inspect node1 for diff if node2 is given
hgkw/keyword.py
--- a/hgkw/keyword.py	Thu Feb 14 13:30:17 2008 +0100
+++ b/hgkw/keyword.py	Thu Feb 14 16:11:54 2008 +0100
@@ -124,7 +124,7 @@
     # only expand if comparing against working dir
     if node2 is not None:
         kwx['templater'].matcher = util.never
-    if node1 is not None and node1 != repo.changectx().node():
+    elif node1 is not None and node1 != repo.changectx().node():
         kwx['templater'].restrict = True
     _patch_diff(repo, node1=node1, node2=node2, files=files, match=match,
                 fp=fp, changes=changes, opts=opts)