mercurial/hgweb/hgweb_mod.py
changeset 3406 970b2d6de3b3
parent 3403 372999405787
child 3407 03e7e8958a27
--- a/mercurial/hgweb/hgweb_mod.py	Sun Oct 15 20:57:30 2006 -0700
+++ b/mercurial/hgweb/hgweb_mod.py	Sun Oct 15 21:20:15 2006 -0700
@@ -553,8 +553,8 @@
     def filediff(self, fctx):
         n = fctx.node()
         path = fctx.path()
-        parents = fctx.changectx().parents()
-        p1 = parents[0].node()
+        parents = fctx.parents()
+        p1 = parents and parents[0].node() or nullid
 
         def diff(**map):
             yield self.diff(p1, n, [path])