fix: wrong folder in data
This commit is contained in:
parent
12ce6d4e22
commit
862de2f9d2
@ -158,7 +158,6 @@ class SeriesApp:
|
|||||||
index = int(selection) - 1
|
index = int(selection) - 1
|
||||||
if 0 <= index < len(results):
|
if 0 <= index < len(results):
|
||||||
chosen_name = results[index]
|
chosen_name = results[index]
|
||||||
|
|
||||||
self.List.add(Serie(chosen_name["link"], chosen_name["name"], "aniworld.to", chosen_name["link"], {}))
|
self.List.add(Serie(chosen_name["link"], chosen_name["name"], "aniworld.to", chosen_name["link"], {}))
|
||||||
return
|
return
|
||||||
else:
|
else:
|
||||||
@ -166,6 +165,7 @@ class SeriesApp:
|
|||||||
except ValueError:
|
except ValueError:
|
||||||
print("Invalid input. Try again.")
|
print("Invalid input. Try again.")
|
||||||
|
|
||||||
|
|
||||||
def run(self):
|
def run(self):
|
||||||
"""Main function to run the app."""
|
"""Main function to run the app."""
|
||||||
while True:
|
while True:
|
||||||
|
|||||||
@ -31,10 +31,12 @@ class SerieScanner:
|
|||||||
if (serie != None and not self.is_null_or_whitespace(serie.key)):
|
if (serie != None and not self.is_null_or_whitespace(serie.key)):
|
||||||
missings, site = self.__GetMissingEpisodesAndSeason(serie.key, mp4_files)
|
missings, site = self.__GetMissingEpisodesAndSeason(serie.key, mp4_files)
|
||||||
serie.episodeDict = missings
|
serie.episodeDict = missings
|
||||||
|
serie.folder = folder
|
||||||
serie.save_to_file(os.path.join(os.path.join(self.directory, folder), 'data'))
|
serie.save_to_file(os.path.join(os.path.join(self.directory, folder), 'data'))
|
||||||
if folder not in self.folderDict:
|
if (serie.key in self.folderDict):
|
||||||
self.folderDict[folder] = []
|
logging.ERROR(f"dublication found: {serie.key}");
|
||||||
self.folderDict[folder] = serie
|
pass
|
||||||
|
self.folderDict[serie.key] = serie
|
||||||
noKeyFound_logger.info(f"Saved Serie: '{str(serie)}'")
|
noKeyFound_logger.info(f"Saved Serie: '{str(serie)}'")
|
||||||
except NoKeyFoundException as nkfe:
|
except NoKeyFoundException as nkfe:
|
||||||
NoKeyFoundException.error(f"Error processing folder '{folder}': {nkfe}")
|
NoKeyFoundException.error(f"Error processing folder '{folder}': {nkfe}")
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user