equal
deleted
inserted
replaced
856 |
856 |
857 parsecontext = lambda v: v == 'full' and -1 or int(v) |
857 parsecontext = lambda v: v == 'full' and -1 or int(v) |
858 if 'context' in web.req.qsparams: |
858 if 'context' in web.req.qsparams: |
859 context = parsecontext(web.req.qsparams['context']) |
859 context = parsecontext(web.req.qsparams['context']) |
860 else: |
860 else: |
861 context = parsecontext(web.config('web', 'comparisoncontext', '5')) |
861 context = parsecontext(web.config('web', 'comparisoncontext')) |
862 |
862 |
863 def filelines(f): |
863 def filelines(f): |
864 if f.isbinary(): |
864 if f.isbinary(): |
865 mt = pycompat.sysbytes( |
865 mt = pycompat.sysbytes( |
866 mimetypes.guess_type(pycompat.fsdecode(f.path()))[0] |
866 mimetypes.guess_type(pycompat.fsdecode(f.path()))[0] |