Snake case

main
Bob Mottram 2022-01-01 20:36:56 +00:00
parent 1e84835193
commit fd2dfb0438
3 changed files with 657 additions and 652 deletions

1295
daemon.py

File diff suppressed because it is too large Load Diff

View File

@ -92,7 +92,7 @@ def masto_api_v1_response(path: str, calling_domain: str,
registration: bool, registration: bool,
system_language: str, system_language: str,
project_version: str, project_version: str,
customEmoji: [], custom_emoji: [],
show_node_info_accounts: bool, show_node_info_accounts: bool,
broch_mode: bool) -> ({}, str): broch_mode: bool) -> ({}, str):
"""This is a vestigil mastodon API for the purpose """This is a vestigil mastodon API for the purpose
@ -192,7 +192,7 @@ def masto_api_v1_response(path: str, calling_domain: str,
} }
sendJsonStr = 'masto API timelines sent ' + path + callingInfo sendJsonStr = 'masto API timelines sent ' + path + callingInfo
elif path.startswith('/api/v1/custom_emojis'): elif path.startswith('/api/v1/custom_emojis'):
sendJson = customEmoji sendJson = custom_emoji
sendJsonStr = \ sendJsonStr = \
'masto API custom emojis sent ' + path + callingInfo 'masto API custom emojis sent ' + path + callingInfo

View File

@ -59,7 +59,7 @@ def html_search_emoji(css_cache: {}, translate: {},
css_filename = base_dir + '/epicyon.css' css_filename = base_dir + '/epicyon.css'
emojiLookupFilename = base_dir + '/emoji/emoji.json' emojiLookupFilename = base_dir + '/emoji/emoji.json'
customEmojiLookupFilename = base_dir + '/emojicustom/emoji.json' custom_emoji_lookup_filename = base_dir + '/emojicustom/emoji.json'
# create header # create header
instanceTitle = \ instanceTitle = \
@ -79,10 +79,10 @@ def html_search_emoji(css_cache: {}, translate: {},
emojiJson = load_json(emojiLookupFilename) emojiJson = load_json(emojiLookupFilename)
if emojiJson: if emojiJson:
if os.path.isfile(customEmojiLookupFilename): if os.path.isfile(custom_emoji_lookup_filename):
customEmojiJson = load_json(customEmojiLookupFilename) custom_emoji_json = load_json(custom_emoji_lookup_filename)
if customEmojiJson: if custom_emoji_json:
emojiJson = dict(emojiJson, **customEmojiJson) emojiJson = dict(emojiJson, **custom_emoji_json)
results = {} results = {}
for emojiName, filename in emojiJson.items(): for emojiName, filename in emojiJson.items():