From b03f434329ac7b0b05509e1f2589fc9a7e42e364 Mon Sep 17 00:00:00 2001 From: Taloth Saldono Date: Sat, 1 Jul 2017 14:24:59 +0200 Subject: [PATCH] Disable Nyaa forcibly. --- .../Datastore/Migration/116_disable_nyaa.cs | 14 ++++++++++++++ src/NzbDrone.Core/Indexers/Nyaa/NyaaSettings.cs | 2 +- src/NzbDrone.Core/NzbDrone.Core.csproj | 1 + 3 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 src/NzbDrone.Core/Datastore/Migration/116_disable_nyaa.cs diff --git a/src/NzbDrone.Core/Datastore/Migration/116_disable_nyaa.cs b/src/NzbDrone.Core/Datastore/Migration/116_disable_nyaa.cs new file mode 100644 index 000000000..9dcbe0cb0 --- /dev/null +++ b/src/NzbDrone.Core/Datastore/Migration/116_disable_nyaa.cs @@ -0,0 +1,14 @@ +using FluentMigrator; +using NzbDrone.Core.Datastore.Migration.Framework; + +namespace NzbDrone.Core.Datastore.Migration +{ + [Migration(116)] + public class disable_nyaa : NzbDroneMigrationBase + { + protected override void MainDbUpgrade() + { + Execute.Sql("UPDATE Indexers SET EnableRss = 0, EnableSearch = 0, Settings = Replace(Settings, 'https://nyaa.se', '') WHERE Implementation = 'Nyaa' AND Settings LIKE '%nyaa.se%';"); + } + } +} diff --git a/src/NzbDrone.Core/Indexers/Nyaa/NyaaSettings.cs b/src/NzbDrone.Core/Indexers/Nyaa/NyaaSettings.cs index 105686a9b..33661c6d4 100644 --- a/src/NzbDrone.Core/Indexers/Nyaa/NyaaSettings.cs +++ b/src/NzbDrone.Core/Indexers/Nyaa/NyaaSettings.cs @@ -19,7 +19,7 @@ namespace NzbDrone.Core.Indexers.Nyaa public NyaaSettings() { - BaseUrl = "https://www.nyaa.se"; + BaseUrl = ""; AdditionalParameters = "&cats=1_37&filter=1"; MinimumSeeders = IndexerDefaults.MINIMUM_SEEDERS; } diff --git a/src/NzbDrone.Core/NzbDrone.Core.csproj b/src/NzbDrone.Core/NzbDrone.Core.csproj index 90c5fcb9b..0321d4683 100644 --- a/src/NzbDrone.Core/NzbDrone.Core.csproj +++ b/src/NzbDrone.Core/NzbDrone.Core.csproj @@ -249,6 +249,7 @@ +