major edge case
This commit is contained in:
parent
b0257d153b
commit
dcf6f71f38
@ -254,7 +254,8 @@ class LibraryTab(ctk.CTkScrollableFrame):
|
||||
mod_count += 1 if item_type == "mod" else 0
|
||||
if curr_folder_name not in self.added_folders:
|
||||
image_path = mod_img if item_type == "mod" else map_img
|
||||
if not (str(curr_folder_name).strip() == str(workshop_id).strip() or str(curr_folder_name).strip() == str(folder_name).strip()):
|
||||
if not (str(curr_folder_name).strip() == str(workshop_id).strip() or str(curr_folder_name).strip() == str(folder_name).strip()
|
||||
or str(curr_folder_name).strip() == f"{folder_name}_{workshop_id}"):
|
||||
try: self.remove_item_by_option(items_file, curr_folder_name, "folder_name")
|
||||
except: pass
|
||||
self.item_block_list.add(curr_folder_name)
|
||||
@ -300,7 +301,9 @@ class LibraryTab(ctk.CTkScrollableFrame):
|
||||
|
||||
# keep here cuz of item_exists_in_file() testing
|
||||
self.added_folders.add(curr_folder_name)
|
||||
if not workshop_id in self.ids_added:
|
||||
# added that cuz it sometimes can add blocked ids first
|
||||
# and legit ids will be blocked cuz theyll be added to "ids_added"
|
||||
if not workshop_id in self.ids_added and curr_folder_name not in self.item_block_list:
|
||||
self.ids_added.add(workshop_id)
|
||||
|
||||
if not self.file_cleaned and os.path.exists(items_file):
|
||||
|
@ -412,7 +412,7 @@ class SettingsTab(ctk.CTkFrame):
|
||||
zone_path = os.path.join(folder_path, folder_name, "zone")
|
||||
if not os.path.isdir(zone_path):
|
||||
continue
|
||||
if zone_path in main_app.app.library_tab.item_block_list:
|
||||
if folder_name in main_app.app.library_tab.item_block_list:
|
||||
continue
|
||||
json_path = os.path.join(zone_path, "workshop.json")
|
||||
if os.path.exists(json_path):
|
||||
|
Loading…
Reference in New Issue
Block a user