Fix some lint errors

This commit is contained in:
Map 2024-10-07 03:57:39 -05:00
parent e06db742e2
commit 301035bad1
2 changed files with 5 additions and 5 deletions

View file

@ -156,9 +156,9 @@ default persistent.autoup = False
default persistent.show_mod_screenshots = True
default persistent.gallery_edgescroll = True
init -1000 python:
init -999 python:
if persistent.newmods_default_state == None:
persistent.newmods_default_state = True
persistent.newmods_default_state = False
init python:
# No idea what this does

View file

@ -196,7 +196,7 @@ init -999 python:
mod_jsonfail_list = [] # List of languages that has an associated metadata language file that failed to load.
mod_preferred_modname = []
mod_exception = False
mod_in_root_folder = file.count("/", len(mods_dir)) is 0
mod_in_root_folder = file.count("/", len(mods_dir)) == 0
mod_folder_name = file.split("/")[-2]
# mod_name is used only to display debugging information via mod_menu_errorcodes. Contains the mod folder name and whatever translations of
# the mod's name that exist. Kind of a cursed implemnetation but with how early error reporting this is before solidifying the mod name
@ -288,7 +288,7 @@ init -999 python:
# Since lang keys will only be added to the mod data dict if their respective metadata successfully loaded, no need to check if they can.
for lang_key in mod_data_final.keys():
if lang_key is "None" or lang_key in renpy.known_languages():
if lang_key == "None" or lang_key in renpy.known_languages():
lang_data = mod_data_final[lang_key]
# The JSON object returns an actual python list, but renpy only works with it's own list object and the automation for this fails with JSON.
@ -502,7 +502,7 @@ init -999 python:
# Make a copy of the current screenshots list, then put displayable screenshots wherever the values of "Screenshot Displayables" correspond in this list
# mod_screenshots will return an empty list if there were no screenshot files to begin with, so this works fine.
for lang_key in mod_data_final.keys():
if lang_key is "None" or lang_key in renpy.known_languages():
if lang_key == "None" or lang_key in renpy.known_languages():
if mod_data_final[lang_key].get("Screenshots") == None:
mod_screenshots = []
else: