diff options
author | 2022-10-18 04:46:21 -0300 | |
---|---|---|
committer | 2022-10-18 14:44:15 -0300 | |
commit | 801a9951fefd004b6b6b549a3c4bd41e64a8f500 (patch) | |
tree | ea6a5a2330d7ba59b81319a002ef22c655991bc2 | |
parent | sort.py: enumerate lines from 1 (diff) | |
download | firejail-801a9951fefd004b6b6b549a3c4bd41e64a8f500.tar.gz firejail-801a9951fefd004b6b6b549a3c4bd41e64a8f500.tar.zst firejail-801a9951fefd004b6b6b549a3c4bd41e64a8f500.zip |
sort.py: pass the str.casefold function directly
To the sort function, instead of wrapping it in a lambda function.
-rwxr-xr-x | contrib/sort.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/sort.py b/contrib/sort.py index 0758d5fec..9ce57802e 100755 --- a/contrib/sort.py +++ b/contrib/sort.py | |||
@@ -29,7 +29,7 @@ from sys import argv, exit as sys_exit | |||
29 | 29 | ||
30 | def sort_alphabetical(raw_items): | 30 | def sort_alphabetical(raw_items): |
31 | items = raw_items.split(",") | 31 | items = raw_items.split(",") |
32 | items.sort(key=lambda s: s.casefold()) | 32 | items.sort(key=str.casefold) |
33 | return ",".join(items) | 33 | return ",".join(items) |
34 | 34 | ||
35 | 35 | ||