mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-04-25 20:41:15 -03:00
Make fish config work if one of colors is undefined.
This moves the sorting to be done before sorting remaining colors.
This commit is contained in:
@@ -483,15 +483,15 @@ class FishConfigHTTPRequestHandler(SimpleHTTPServer.SimpleHTTPRequestHandler):
|
||||
result.append(data)
|
||||
remaining.discard(color_name)
|
||||
|
||||
# Sort our result (by their keys)
|
||||
result.sort(key=operator.itemgetter('name'))
|
||||
|
||||
# Ensure that we have all the color names we know about, so that if the
|
||||
# user deletes one he can still set it again via the web interface
|
||||
for color_name in remaining:
|
||||
color_desc = descriptions.get(color_name, '')
|
||||
result.append([color_name, color_desc, parse_color('')])
|
||||
|
||||
# Sort our result (by their keys)
|
||||
result.sort(key=operator.itemgetter('name'))
|
||||
|
||||
return result
|
||||
|
||||
def do_get_functions(self):
|
||||
|
||||
Reference in New Issue
Block a user