@ctrl/qbittorrent 2.9.0 → 2.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -1
- package/dist/index.js +6 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
@@ -44,7 +44,7 @@ export declare class QBittorrent implements TorrentClient {
|
|
44
44
|
* @param category Get torrents with the given category (empty string means "without category"; no "category" parameter means "any category")
|
45
45
|
* @returns list of torrents
|
46
46
|
*/
|
47
|
-
listTorrents(hashes?: string | string[], filter?: TorrentFilters, category?: string, sort?: string, offset?: number, reverse?: boolean): Promise<Torrent[]>;
|
47
|
+
listTorrents(hashes?: string | string[], filter?: TorrentFilters, category?: string, sort?: string, offset?: number, reverse?: boolean, tag?: string): Promise<Torrent[]>;
|
48
48
|
getAllData(): Promise<AllClientDataQbittorrent>;
|
49
49
|
/**
|
50
50
|
* {@link https://github.com/qbittorrent/qBittorrent/wiki/WebUI-API-(qBittorrent-4.1)#get-torrent-generic-properties}
|
package/dist/index.js
CHANGED
@@ -86,7 +86,9 @@ class QBittorrent {
|
|
86
86
|
* @returns list of torrents
|
87
87
|
*/
|
88
88
|
// eslint-disable-next-line max-params
|
89
|
-
async listTorrents(hashes, filter, category, sort, offset, reverse
|
89
|
+
async listTorrents(hashes, filter, category, sort, offset, reverse,
|
90
|
+
// TODO: refactor filters into an object with optional properties
|
91
|
+
tag) {
|
90
92
|
const params = {};
|
91
93
|
if (hashes) {
|
92
94
|
params.hashes = this._normalizeHashes(hashes);
|
@@ -97,6 +99,9 @@ class QBittorrent {
|
|
97
99
|
if (category) {
|
98
100
|
params.category = category;
|
99
101
|
}
|
102
|
+
if (tag) {
|
103
|
+
params.tag = tag;
|
104
|
+
}
|
100
105
|
if (offset !== undefined) {
|
101
106
|
params.offset = `${offset}`;
|
102
107
|
}
|