Code formatting
* removed weird linebreaks for for-loop * no () for del statement
This commit is contained in:
parent
0b010d5c10
commit
b1145af6bb
|
@ -527,10 +527,7 @@ class DirListingHandler(FileBaseHandler):
|
||||||
target_items.append((item, itemPath, stat))
|
target_items.append((item, itemPath, stat))
|
||||||
|
|
||||||
# Directories first, then files
|
# Directories first, then files
|
||||||
for (tuple_list, is_dir) in (
|
for (tuple_list, is_dir) in ((dir_items, True), (file_items, False)):
|
||||||
(dir_items, True),
|
|
||||||
(file_items, False),
|
|
||||||
):
|
|
||||||
for (item, itemPath, stat) in tuple_list:
|
for (item, itemPath, stat) in tuple_list:
|
||||||
self._appendToListing(content, item, itemPath, stat, is_dir=is_dir)
|
self._appendToListing(content, item, itemPath, stat, is_dir=is_dir)
|
||||||
|
|
||||||
|
@ -874,7 +871,7 @@ class ServeFile():
|
||||||
if oldLang:
|
if oldLang:
|
||||||
os.environ['LC_ALL'] = oldLang
|
os.environ['LC_ALL'] = oldLang
|
||||||
else:
|
else:
|
||||||
del(os.environ['LC_ALL'])
|
del os.environ['LC_ALL']
|
||||||
if proc.wait() != 0:
|
if proc.wait() != 0:
|
||||||
# we couldn't find any ip address
|
# we couldn't find any ip address
|
||||||
proc = None
|
proc = None
|
||||||
|
|
Loading…
Reference in New Issue