views/tree.html: Fix lambda syntax
Some versions of bottle.py don't deal well with the "if" inside the lambda, so work around it by just using comparison and simplifying the function. Signed-off-by: Alberto Bertogli <albertito@blitiri.com.ar>
This commit is contained in:
parent
eb7cadd64f
commit
47d500715a
@ -36,7 +36,7 @@
|
||||
</h3>
|
||||
|
||||
<table class="nice ls">
|
||||
% key_func = lambda (t, n, s): (0 if t == 'tree' else 1, n.raw)
|
||||
% key_func = lambda (t, n, s): (t != 'tree', n.raw)
|
||||
% for type, name, size in sorted(tree.ls(dirname.raw), key = key_func):
|
||||
<tr class="{{type}}">
|
||||
% if type == "blob":
|
||||
|
Loading…
Reference in New Issue
Block a user