equal
deleted
inserted
replaced
556 raise |
556 raise |
557 |
557 |
558 if fctx is not None: |
558 if fctx is not None: |
559 n = fctx.node() |
559 n = fctx.node() |
560 path = fctx.path() |
560 path = fctx.path() |
|
561 ctx = fctx.changectx() |
561 else: |
562 else: |
562 n = ctx.node() |
563 n = ctx.node() |
563 # path already defined in except clause |
564 # path already defined in except clause |
564 |
565 |
565 parity = paritygen(web.stripecount) |
566 parity = paritygen(web.stripecount) |
566 style = web.config('web', 'style', 'paper') |
567 style = web.config('web', 'style', 'paper') |
567 if 'style' in req.form: |
568 if 'style' in req.form: |
568 style = req.form['style'][0] |
569 style = req.form['style'][0] |
569 |
570 |
570 diffs = webutil.diffs(web.repo, tmpl, fctx or ctx, [path], parity, style) |
571 diffs = webutil.diffs(web.repo, tmpl, ctx, [path], parity, style) |
571 rename = fctx and webutil.renamelink(fctx) or [] |
572 rename = fctx and webutil.renamelink(fctx) or [] |
572 ctx = fctx and fctx or ctx |
573 ctx = fctx and fctx or ctx |
573 return tmpl("filediff", |
574 return tmpl("filediff", |
574 file=path, |
575 file=path, |
575 node=hex(n), |
576 node=hex(n), |