From 48120b9406d74ed284b34f0f91aa29ffddf55834 Mon Sep 17 00:00:00 2001 From: wumode Date: Mon, 12 May 2025 21:05:30 +0800 Subject: [PATCH] fix: get_torrent_tags fails to properly retrieve the existing tags --- app/modules/transmission/transmission.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) mode change 100644 => 100755 app/modules/transmission/transmission.py diff --git a/app/modules/transmission/transmission.py b/app/modules/transmission/transmission.py old mode 100644 new mode 100755 index e9f059d6..6f6437f8 --- a/app/modules/transmission/transmission.py +++ b/app/modules/transmission/transmission.py @@ -163,8 +163,9 @@ class Transmission: if not self.trc: return [] try: - torrent = self.trc.get_torrents(ids=ids, arguments=self._trarg) - if torrent: + torrents = self.trc.get_torrents(ids=ids, arguments=self._trarg) + if len(torrents): + torrent = torrents[0] labels = [str(tag).strip() for tag in torrent.labels] if hasattr(torrent, "labels") else [] return labels