Ver a proveniência

changed cover image handle to be more robust

sharky-custom
sharky555 há 2 anos
ascendente
cometimento
ea9d82cfbc
1 ficheiros alterados com 5 adições e 2 eliminações
  1. +5
    -2
      autoupload.py

+ 5
- 2
autoupload.py Ver ficheiro

@@ -741,8 +741,11 @@ if __name__ == "__main__":
# Folder_name equals the last folder in the path, this is used to rename .torrent files to something relevant.
folder_name = os.path.basename(os.path.normpath(directory))
# Identifying cover.jpg path
cover_path = directory + "/" + cfg['local_prefs']['cover_name']
# Identifying cover path
cover_file = [f for f in os.listdir(directory) if (f.lower() in cfg['local_prefs']['cover_templates'])]
cover_path = directory + "\\" + cover_file[0]
if debug:
print(f"Using cover file: {cover_path}")
# Create torrent file.
torrentfile = createtorrent(authkey, directory, folder_name, releasedata)


Carregando…
Cancelar
Guardar