mirror of
https://github.com/jxxghp/MoviePilot.git
synced 2026-09-05 15:38:19 +08:00
更新 qbittorrent.py
This commit is contained in:
@@ -163,14 +163,12 @@ class Qbittorrent(metaclass=Singleton):
|
|||||||
continue
|
continue
|
||||||
content_path = torrent.get("content_path")
|
content_path = torrent.get("content_path")
|
||||||
if content_path:
|
if content_path:
|
||||||
trans_name = content_path.replace(path, "").replace("\\", "/")
|
torrent_path = Path(content_path)
|
||||||
if trans_name.startswith('/'):
|
|
||||||
trans_name = trans_name[1:]
|
|
||||||
else:
|
else:
|
||||||
trans_name = torrent.get('name')
|
torrent_path = Path(settings.DOWNLOAD_PATH) / torrent.get('name')
|
||||||
trans_tasks.append({
|
trans_tasks.append({
|
||||||
'title': torrent.get('name'),
|
'title': torrent.get('name'),
|
||||||
'path': Path(settings.DOWNLOAD_PATH) / trans_name,
|
'path': torrent_path,
|
||||||
'id': torrent.get('hash'),
|
'id': torrent.get('hash'),
|
||||||
'tags': torrent.get('tags')
|
'tags': torrent.get('tags')
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user