From cb667ed4f868c4814738bc2687cadacc460b0992 Mon Sep 17 00:00:00 2001 From: Timothy Baldridge Date: Wed, 6 Nov 2019 17:29:53 -0700 Subject: [PATCH] Fix broken interaction with http-downloader --- Wabbajack.Lib/Downloaders/DownloadDispatcher.cs | 2 +- Wabbajack.Lib/Downloaders/ManualDownloader.cs | 10 +--------- Wabbajack.Test/DownloaderTests.cs | 5 ----- 3 files changed, 2 insertions(+), 15 deletions(-) diff --git a/Wabbajack.Lib/Downloaders/DownloadDispatcher.cs b/Wabbajack.Lib/Downloaders/DownloadDispatcher.cs index 26b85eca..cd96be83 100644 --- a/Wabbajack.Lib/Downloaders/DownloadDispatcher.cs +++ b/Wabbajack.Lib/Downloaders/DownloadDispatcher.cs @@ -18,8 +18,8 @@ namespace Wabbajack.Lib.Downloaders new ModDBDownloader(), new NexusDownloader(), new MediaFireDownloader(), + new HTTPDownloader(), new ManualDownloader(), - new HTTPDownloader() }; private static readonly Dictionary IndexedDownloaders; diff --git a/Wabbajack.Lib/Downloaders/ManualDownloader.cs b/Wabbajack.Lib/Downloaders/ManualDownloader.cs index b024bbbc..5094d8ab 100644 --- a/Wabbajack.Lib/Downloaders/ManualDownloader.cs +++ b/Wabbajack.Lib/Downloaders/ManualDownloader.cs @@ -15,7 +15,7 @@ using File = System.IO.File; namespace Wabbajack.Lib.Downloaders { - public class ManualDownloader : IUrlDownloader + public class ManualDownloader : IDownloader { private FileSystemWatcher _watcher; private Subject _fileEvents = new Subject(); @@ -72,14 +72,6 @@ namespace Wabbajack.Lib.Downloaders { } - public AbstractDownloadState GetDownloaderState(string url) - { - return new State - { - Url = url - }; - } - public class State : AbstractDownloadState { public string Url { get; set; } diff --git a/Wabbajack.Test/DownloaderTests.cs b/Wabbajack.Test/DownloaderTests.cs index 61141418..0a490a13 100644 --- a/Wabbajack.Test/DownloaderTests.cs +++ b/Wabbajack.Test/DownloaderTests.cs @@ -157,11 +157,6 @@ namespace Wabbajack.Test Assert.IsNotNull(state); - var url_state = DownloadDispatcher.ResolveArchive("http://build.wabbajack.org/WABBAJACK_TEST_FILE.zip"); - - Assert.AreEqual("http://build.wabbajack.org/WABBAJACK_TEST_FILE.zip", - ((ManualDownloader.State)url_state).Url); - var converted = state.ViaJSON(); Assert.IsTrue(converted.Verify()); var filename = Guid.NewGuid().ToString();