diff --git a/src/Jackett.Common/Definitions/nyaasi.yml b/src/Jackett.Common/Definitions/nyaasi.yml index fc315ba29..324e6d6d8 100644 --- a/src/Jackett.Common/Definitions/nyaasi.yml +++ b/src/Jackett.Common/Definitions/nyaasi.yml @@ -27,6 +27,10 @@ legacylinks: - https://nyaa.nocensor.art/ settings: + - name: prefer_magnet_links + type: checkbox + label: Prefer Magnet Links + default: true - name: filter-id type: select label: Filter @@ -155,10 +159,13 @@ search: details: selector: td:nth-child(2) a:last-of-type attribute: href - download: + download_optional: selector: td:nth-child(3) a[href$=".torrent"] attribute: href optional: true + download: + text: "{{ if .Config.prefer_magnet_links }}{{ else }}{{ .Result.download_optional }}{{ end }}" + optional: true magnet: selector: td:nth-child(3) a[href^="magnet:?"] attribute: href