From 0c1ce66053373bba97b2dcced39989610a27c0f8 Mon Sep 17 00:00:00 2001 From: Qstick Date: Wed, 7 Aug 2019 22:08:03 -0400 Subject: [PATCH] Cleanup Multiple Compiler Warnings --- src/NzbDrone.Api.Test/NzbDrone.Api.Test.csproj | 4 ---- src/NzbDrone.Api/NzbDrone.Api.csproj | 3 --- src/NzbDrone.App.Test/NzbDrone.Host.Test.csproj | 3 --- src/NzbDrone.Automation.Test/AutomationTest.cs | 4 ++-- src/NzbDrone.Common.Test/NzbDrone.Common.Test.csproj | 3 --- src/NzbDrone.Console/NzbDrone.Console.csproj | 3 --- .../Datastore/Converters/Int32ConverterFixture.cs | 2 +- .../Aggregation/Aggregators/AggregateQualityFixture.cs | 2 -- src/NzbDrone.Core.Test/NzbDrone.Core.Test.csproj | 7 ------- .../FileNameBuilderTests/RequiresEpisodeTitleFixture.cs | 2 -- .../TvTests/RefreshEpisodeServiceFixture.cs | 2 +- src/NzbDrone.Core/Download/Clients/Hadouken/Hadouken.cs | 4 ++-- .../Download/Clients/Hadouken/HadoukenProxy.cs | 3 +-- .../Extras/Metadata/ExistingMetadataImporter.cs | 2 +- .../Extras/Others/ExistingOtherExtraImporter.cs | 2 +- .../Extras/Subtitles/ExistingSubtitleImporter.cs | 2 +- src/NzbDrone.Core/Messaging/Commands/CommandExecutor.cs | 2 +- .../Notifications/Plex/PlexTv/PlexTvProxy.cs | 2 +- src/NzbDrone.Core/Tv/MoveSeriesService.cs | 2 -- src/NzbDrone.Host/NzbDrone.Host.csproj | 3 --- .../Owin/MiddleWare/NzbDroneVersionMiddleWare.cs | 2 +- src/NzbDrone.Integration.Test/CorsFixture.cs | 1 - .../NzbDrone.Integration.Test.csproj | 3 --- src/NzbDrone.Test.Common/NzbDrone.Test.Common.csproj | 3 --- src/NzbDrone.Update.Test/NzbDrone.Update.Test.csproj | 3 --- src/Sonarr.Api.V3/EpisodeFiles/EpisodeFileModule.cs | 1 - .../Profiles/Release/ReleaseProfileModule.cs | 8 ++++---- src/Sonarr.Api.V3/Tags/TagDetailsModule.cs | 4 ++-- src/Sonarr.Api.V3/Tags/TagModule.cs | 8 ++++---- src/Sonarr.Http/Frontend/Mappers/BackupFileMapper.cs | 2 -- src/Sonarr.Http/TinyIoCNancyBootstrapper.cs | 2 -- 31 files changed, 23 insertions(+), 71 deletions(-) diff --git a/src/NzbDrone.Api.Test/NzbDrone.Api.Test.csproj b/src/NzbDrone.Api.Test/NzbDrone.Api.Test.csproj index 022743424..6897b0f7b 100644 --- a/src/NzbDrone.Api.Test/NzbDrone.Api.Test.csproj +++ b/src/NzbDrone.Api.Test/NzbDrone.Api.Test.csproj @@ -50,10 +50,6 @@ ..\packages\FluentAssertions.4.19.0\lib\net40\FluentAssertions.Core.dll - - True - ..\packages\FluentAssertions.4.19.0\lib\net45\FluentAssertions.Core.dll - ..\packages\NUnit.3.6.0\lib\net45\nunit.framework.dll diff --git a/src/NzbDrone.Api/NzbDrone.Api.csproj b/src/NzbDrone.Api/NzbDrone.Api.csproj index 05f24f664..175d4a7e7 100644 --- a/src/NzbDrone.Api/NzbDrone.Api.csproj +++ b/src/NzbDrone.Api/NzbDrone.Api.csproj @@ -75,9 +75,6 @@ - - ..\packages\ValueInjecter.2.3.3\lib\net35\Omu.ValueInjecter.dll - diff --git a/src/NzbDrone.App.Test/NzbDrone.Host.Test.csproj b/src/NzbDrone.App.Test/NzbDrone.Host.Test.csproj index d4b5c93fc..dd99f67ea 100644 --- a/src/NzbDrone.App.Test/NzbDrone.Host.Test.csproj +++ b/src/NzbDrone.App.Test/NzbDrone.Host.Test.csproj @@ -49,9 +49,6 @@ ..\packages\FluentAssertions.4.19.0\lib\net45\FluentAssertions.Core.dll - - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll True diff --git a/src/NzbDrone.Automation.Test/AutomationTest.cs b/src/NzbDrone.Automation.Test/AutomationTest.cs index 9f493d824..47f8d87c0 100644 --- a/src/NzbDrone.Automation.Test/AutomationTest.cs +++ b/src/NzbDrone.Automation.Test/AutomationTest.cs @@ -31,7 +31,7 @@ namespace NzbDrone.Automation.Test LogManager.Configuration.LoggingRules.Add(new LoggingRule("*", NLog.LogLevel.Trace, consoleTarget)); } - [TestFixtureSetUp] + [OneTimeSetUp] public void SmokeTestSetup() { driver = new FirefoxDriver(); @@ -56,7 +56,7 @@ namespace NzbDrone.Automation.Test .Select(e => e.Text); } - [TestFixtureTearDown] + [OneTimeTearDown] public void SmokeTestTearDown() { _runner.KillAll(); diff --git a/src/NzbDrone.Common.Test/NzbDrone.Common.Test.csproj b/src/NzbDrone.Common.Test/NzbDrone.Common.Test.csproj index 7d28931b1..29349bc2b 100644 --- a/src/NzbDrone.Common.Test/NzbDrone.Common.Test.csproj +++ b/src/NzbDrone.Common.Test/NzbDrone.Common.Test.csproj @@ -46,9 +46,6 @@ ..\packages\FluentAssertions.4.19.0\lib\net45\FluentAssertions.Core.dll - - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll True diff --git a/src/NzbDrone.Console/NzbDrone.Console.csproj b/src/NzbDrone.Console/NzbDrone.Console.csproj index 6edb4c608..96890d9f0 100644 --- a/src/NzbDrone.Console/NzbDrone.Console.csproj +++ b/src/NzbDrone.Console/NzbDrone.Console.csproj @@ -82,9 +82,6 @@ - - ..\packages\Owin.1.0\lib\net40\Owin.dll - ..\packages\Owin.1.0\lib\net40\Owin.dll diff --git a/src/NzbDrone.Core.Test/Datastore/Converters/Int32ConverterFixture.cs b/src/NzbDrone.Core.Test/Datastore/Converters/Int32ConverterFixture.cs index 2c10a0aaf..ed2fee734 100644 --- a/src/NzbDrone.Core.Test/Datastore/Converters/Int32ConverterFixture.cs +++ b/src/NzbDrone.Core.Test/Datastore/Converters/Int32ConverterFixture.cs @@ -15,7 +15,7 @@ namespace NzbDrone.Core.Test.Datastore.Converters { var i = 5; - Subject.ToDB(5).Should().Be(5); + Subject.ToDB(i).Should().Be(5); } [Test] diff --git a/src/NzbDrone.Core.Test/MediaFiles/EpisodeImport/Aggregation/Aggregators/AggregateQualityFixture.cs b/src/NzbDrone.Core.Test/MediaFiles/EpisodeImport/Aggregation/Aggregators/AggregateQualityFixture.cs index 3b39c8526..75588be1f 100644 --- a/src/NzbDrone.Core.Test/MediaFiles/EpisodeImport/Aggregation/Aggregators/AggregateQualityFixture.cs +++ b/src/NzbDrone.Core.Test/MediaFiles/EpisodeImport/Aggregation/Aggregators/AggregateQualityFixture.cs @@ -18,8 +18,6 @@ namespace NzbDrone.Core.Test.MediaFiles.EpisodeImport.Aggregation.Aggregators private Mock _fileExtensionAugmenter; private Mock _nameAugmenter; - private IEnumerable _qualityAugmenters; - [SetUp] public void Setup() { diff --git a/src/NzbDrone.Core.Test/NzbDrone.Core.Test.csproj b/src/NzbDrone.Core.Test/NzbDrone.Core.Test.csproj index acbfb0aa7..eccad5401 100644 --- a/src/NzbDrone.Core.Test/NzbDrone.Core.Test.csproj +++ b/src/NzbDrone.Core.Test/NzbDrone.Core.Test.csproj @@ -75,13 +75,6 @@ ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll - - - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll - True - - - ..\packages\NCrunch.Framework.3.2.0.3\lib\NCrunch.Framework.dll True diff --git a/src/NzbDrone.Core.Test/OrganizerTests/FileNameBuilderTests/RequiresEpisodeTitleFixture.cs b/src/NzbDrone.Core.Test/OrganizerTests/FileNameBuilderTests/RequiresEpisodeTitleFixture.cs index 9906c52f3..94c278e74 100644 --- a/src/NzbDrone.Core.Test/OrganizerTests/FileNameBuilderTests/RequiresEpisodeTitleFixture.cs +++ b/src/NzbDrone.Core.Test/OrganizerTests/FileNameBuilderTests/RequiresEpisodeTitleFixture.cs @@ -2,7 +2,6 @@ using System.Collections.Generic; using FizzWare.NBuilder; using FluentAssertions; using NUnit.Framework; -using NzbDrone.Core.MediaFiles; using NzbDrone.Core.Organizer; using NzbDrone.Core.Test.Framework; using NzbDrone.Core.Tv; @@ -14,7 +13,6 @@ namespace NzbDrone.Core.Test.OrganizerTests.FileNameBuilderTests { private Series _series; private Episode _episode; - private EpisodeFile _episodeFile; private NamingConfig _namingConfig; [SetUp] diff --git a/src/NzbDrone.Core.Test/TvTests/RefreshEpisodeServiceFixture.cs b/src/NzbDrone.Core.Test/TvTests/RefreshEpisodeServiceFixture.cs index 8f08e7e1d..4fb68adc4 100644 --- a/src/NzbDrone.Core.Test/TvTests/RefreshEpisodeServiceFixture.cs +++ b/src/NzbDrone.Core.Test/TvTests/RefreshEpisodeServiceFixture.cs @@ -20,7 +20,7 @@ namespace NzbDrone.Core.Test.TvTests private List _deletedEpisodes; private Tuple> _gameOfThrones; - [TestFixtureSetUp] + [OneTimeSetUp] public void TestFixture() { UseRealHttp(); diff --git a/src/NzbDrone.Core/Download/Clients/Hadouken/Hadouken.cs b/src/NzbDrone.Core/Download/Clients/Hadouken/Hadouken.cs index 41473fa33..700320779 100644 --- a/src/NzbDrone.Core/Download/Clients/Hadouken/Hadouken.cs +++ b/src/NzbDrone.Core/Download/Clients/Hadouken/Hadouken.cs @@ -160,7 +160,7 @@ namespace NzbDrone.Core.Download.Clients.Hadouken } catch (DownloadClientAuthenticationException ex) { - _logger.ErrorException(ex.Message, ex); + _logger.Error(ex, ex.Message); return new NzbDroneValidationFailure("Password", "Authentication failed"); } @@ -176,7 +176,7 @@ namespace NzbDrone.Core.Download.Clients.Hadouken } catch (Exception ex) { - _logger.ErrorException(ex.Message, ex); + _logger.Error(ex, ex.Message); return new NzbDroneValidationFailure(String.Empty, "Failed to get the list of torrents: " + ex.Message); } diff --git a/src/NzbDrone.Core/Download/Clients/Hadouken/HadoukenProxy.cs b/src/NzbDrone.Core/Download/Clients/Hadouken/HadoukenProxy.cs index e9eb8e651..4fa1c99e4 100644 --- a/src/NzbDrone.Core/Download/Clients/Hadouken/HadoukenProxy.cs +++ b/src/NzbDrone.Core/Download/Clients/Hadouken/HadoukenProxy.cs @@ -21,7 +21,6 @@ namespace NzbDrone.Core.Download.Clients.Hadouken public class HadoukenProxy : IHadoukenProxy { - private static int _callId; private readonly IHttpClient _httpClient; private readonly Logger _logger; @@ -147,7 +146,7 @@ namespace NzbDrone.Core.Download.Clients.Hadouken } catch(Exception ex) { - _logger.ErrorException("Failed to map Hadouken torrent data.", ex); + _logger.Error(ex, "Failed to map Hadouken torrent data."); } return torrent; diff --git a/src/NzbDrone.Core/Extras/Metadata/ExistingMetadataImporter.cs b/src/NzbDrone.Core/Extras/Metadata/ExistingMetadataImporter.cs index e43949142..8bd0178d1 100644 --- a/src/NzbDrone.Core/Extras/Metadata/ExistingMetadataImporter.cs +++ b/src/NzbDrone.Core/Extras/Metadata/ExistingMetadataImporter.cs @@ -73,7 +73,7 @@ namespace NzbDrone.Core.Extras.Metadata { _aggregationService.Augment(localEpisode, false); } - catch (AugmentingFailedException ex) + catch (AugmentingFailedException) { _logger.Debug("Unable to parse extra file: {0}", possibleMetadataFile); continue; diff --git a/src/NzbDrone.Core/Extras/Others/ExistingOtherExtraImporter.cs b/src/NzbDrone.Core/Extras/Others/ExistingOtherExtraImporter.cs index 23e422eda..c1d5bc376 100644 --- a/src/NzbDrone.Core/Extras/Others/ExistingOtherExtraImporter.cs +++ b/src/NzbDrone.Core/Extras/Others/ExistingOtherExtraImporter.cs @@ -58,7 +58,7 @@ namespace NzbDrone.Core.Extras.Others { _aggregationService.Augment(localEpisode, false); } - catch (AugmentingFailedException ex) + catch (AugmentingFailedException) { _logger.Debug("Unable to parse extra file: {0}", possibleExtraFile); continue; diff --git a/src/NzbDrone.Core/Extras/Subtitles/ExistingSubtitleImporter.cs b/src/NzbDrone.Core/Extras/Subtitles/ExistingSubtitleImporter.cs index 79c4544b1..2e6f950cb 100644 --- a/src/NzbDrone.Core/Extras/Subtitles/ExistingSubtitleImporter.cs +++ b/src/NzbDrone.Core/Extras/Subtitles/ExistingSubtitleImporter.cs @@ -53,7 +53,7 @@ namespace NzbDrone.Core.Extras.Subtitles { _aggregationService.Augment(localEpisode, false); } - catch (AugmentingFailedException ex) + catch (AugmentingFailedException) { _logger.Debug("Unable to parse extra file: {0}", possibleSubtitleFile); continue; diff --git a/src/NzbDrone.Core/Messaging/Commands/CommandExecutor.cs b/src/NzbDrone.Core/Messaging/Commands/CommandExecutor.cs index 9d7cf4a50..85d8a00f4 100644 --- a/src/NzbDrone.Core/Messaging/Commands/CommandExecutor.cs +++ b/src/NzbDrone.Core/Messaging/Commands/CommandExecutor.cs @@ -51,7 +51,7 @@ namespace NzbDrone.Core.Messaging.Commands _logger.Error(ex, "Thread aborted"); Thread.ResetAbort(); } - catch (OperationCanceledException ex) + catch (OperationCanceledException) { _logger.Trace("Stopped one command execution pipeline"); } diff --git a/src/NzbDrone.Core/Notifications/Plex/PlexTv/PlexTvProxy.cs b/src/NzbDrone.Core/Notifications/Plex/PlexTv/PlexTvProxy.cs index ce019093a..18e4f6608 100644 --- a/src/NzbDrone.Core/Notifications/Plex/PlexTv/PlexTvProxy.cs +++ b/src/NzbDrone.Core/Notifications/Plex/PlexTv/PlexTvProxy.cs @@ -68,7 +68,7 @@ namespace NzbDrone.Core.Notifications.Plex.PlexTv { throw new NzbDroneClientException(ex.Response.StatusCode, "Unable to connect to plex.tv"); } - catch (WebException ex) + catch (WebException) { throw new NzbDroneClientException(HttpStatusCode.BadRequest, "Unable to connect to plex.tv"); } diff --git a/src/NzbDrone.Core/Tv/MoveSeriesService.cs b/src/NzbDrone.Core/Tv/MoveSeriesService.cs index 705f19e54..015b171bc 100644 --- a/src/NzbDrone.Core/Tv/MoveSeriesService.cs +++ b/src/NzbDrone.Core/Tv/MoveSeriesService.cs @@ -5,7 +5,6 @@ using NzbDrone.Common.Instrumentation.Extensions; using NzbDrone.Core.Messaging.Commands; using NzbDrone.Core.Messaging.Events; using NzbDrone.Core.Organizer; -using NzbDrone.Core.RootFolders; using NzbDrone.Core.Tv.Commands; using NzbDrone.Core.Tv.Events; @@ -17,7 +16,6 @@ namespace NzbDrone.Core.Tv private readonly IBuildFileNames _filenameBuilder; private readonly IDiskProvider _diskProvider; private readonly IDiskTransferService _diskTransferService; - private readonly IRootFolderService _rootFolderService; private readonly IEventAggregator _eventAggregator; private readonly Logger _logger; diff --git a/src/NzbDrone.Host/NzbDrone.Host.csproj b/src/NzbDrone.Host/NzbDrone.Host.csproj index daba89e84..727f69349 100644 --- a/src/NzbDrone.Host/NzbDrone.Host.csproj +++ b/src/NzbDrone.Host/NzbDrone.Host.csproj @@ -96,9 +96,6 @@ ..\packages\NLog.4.5.3\lib\net45\NLog.dll - - ..\packages\NLog.Extensions.Logging.1.1.0\lib\net462\NLog.Extensions.Logging.dll - ..\packages\Owin.1.0\lib\net40\Owin.dll diff --git a/src/NzbDrone.Host/Owin/MiddleWare/NzbDroneVersionMiddleWare.cs b/src/NzbDrone.Host/Owin/MiddleWare/NzbDroneVersionMiddleWare.cs index 2b875d963..ca3c79fdb 100644 --- a/src/NzbDrone.Host/Owin/MiddleWare/NzbDroneVersionMiddleWare.cs +++ b/src/NzbDrone.Host/Owin/MiddleWare/NzbDroneVersionMiddleWare.cs @@ -37,7 +37,7 @@ namespace NzbDrone.Host.Owin.MiddleWare context.Response.Headers.Add(_versionHeader); await Next.Invoke(context); } - catch (Exception ex) + catch (Exception) { Logger.Debug("Unable to set version header"); } diff --git a/src/NzbDrone.Integration.Test/CorsFixture.cs b/src/NzbDrone.Integration.Test/CorsFixture.cs index fc2857453..f4dedc839 100644 --- a/src/NzbDrone.Integration.Test/CorsFixture.cs +++ b/src/NzbDrone.Integration.Test/CorsFixture.cs @@ -2,7 +2,6 @@ using NUnit.Framework; using Sonarr.Http.Extensions; using RestSharp; -using Sonarr.Http.Extensions; namespace NzbDrone.Integration.Test { diff --git a/src/NzbDrone.Integration.Test/NzbDrone.Integration.Test.csproj b/src/NzbDrone.Integration.Test/NzbDrone.Integration.Test.csproj index bbc79293c..0aafb8dac 100644 --- a/src/NzbDrone.Integration.Test/NzbDrone.Integration.Test.csproj +++ b/src/NzbDrone.Integration.Test/NzbDrone.Integration.Test.csproj @@ -62,9 +62,6 @@ ..\packages\Microsoft.Owin.Hosting.3.1.0\lib\net45\Microsoft.Owin.Hosting.dll - - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll True diff --git a/src/NzbDrone.Test.Common/NzbDrone.Test.Common.csproj b/src/NzbDrone.Test.Common/NzbDrone.Test.Common.csproj index 45a725580..a067d4aee 100644 --- a/src/NzbDrone.Test.Common/NzbDrone.Test.Common.csproj +++ b/src/NzbDrone.Test.Common/NzbDrone.Test.Common.csproj @@ -58,9 +58,6 @@ ..\packages\Unity.2.1.505.2\lib\NET35\Microsoft.Practices.Unity.Configuration.dll - - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll True diff --git a/src/NzbDrone.Update.Test/NzbDrone.Update.Test.csproj b/src/NzbDrone.Update.Test/NzbDrone.Update.Test.csproj index 0c4e5726a..22e0e4805 100644 --- a/src/NzbDrone.Update.Test/NzbDrone.Update.Test.csproj +++ b/src/NzbDrone.Update.Test/NzbDrone.Update.Test.csproj @@ -48,9 +48,6 @@ ..\packages\FluentAssertions.4.19.0\lib\net45\FluentAssertions.Core.dll - - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll - ..\packages\Moq.4.0.10827\lib\NET40\Moq.dll True diff --git a/src/Sonarr.Api.V3/EpisodeFiles/EpisodeFileModule.cs b/src/Sonarr.Api.V3/EpisodeFiles/EpisodeFileModule.cs index 279195f7c..64259800b 100644 --- a/src/Sonarr.Api.V3/EpisodeFiles/EpisodeFileModule.cs +++ b/src/Sonarr.Api.V3/EpisodeFiles/EpisodeFileModule.cs @@ -23,7 +23,6 @@ namespace Sonarr.Api.V3.EpisodeFiles { private readonly IMediaFileService _mediaFileService; private readonly IDeleteMediaFiles _mediaFileDeletionService; - private readonly IRecycleBinProvider _recycleBinProvider; private readonly ISeriesService _seriesService; private readonly IUpgradableSpecification _upgradableSpecification; diff --git a/src/Sonarr.Api.V3/Profiles/Release/ReleaseProfileModule.cs b/src/Sonarr.Api.V3/Profiles/Release/ReleaseProfileModule.cs index 932d309fb..c87662357 100644 --- a/src/Sonarr.Api.V3/Profiles/Release/ReleaseProfileModule.cs +++ b/src/Sonarr.Api.V3/Profiles/Release/ReleaseProfileModule.cs @@ -15,11 +15,11 @@ namespace Sonarr.Api.V3.Profiles.Release { _releaseProfileService = releaseProfileService; - GetResourceById = Get; + GetResourceById = GetReleaseProfile; GetResourceAll = GetAll; CreateResource = Create; UpdateResource = Update; - DeleteResource = Delete; + DeleteResource = DeleteReleaseProfile; SharedValidator.Custom(restriction => { @@ -32,7 +32,7 @@ namespace Sonarr.Api.V3.Profiles.Release }); } - private ReleaseProfileResource Get(int id) + private ReleaseProfileResource GetReleaseProfile(int id) { return _releaseProfileService.Get(id).ToResource(); } @@ -52,7 +52,7 @@ namespace Sonarr.Api.V3.Profiles.Release _releaseProfileService.Update(resource.ToModel()); } - private void Delete(int id) + private void DeleteReleaseProfile(int id) { _releaseProfileService.Delete(id); } diff --git a/src/Sonarr.Api.V3/Tags/TagDetailsModule.cs b/src/Sonarr.Api.V3/Tags/TagDetailsModule.cs index 3e5b06db0..16a1bc639 100644 --- a/src/Sonarr.Api.V3/Tags/TagDetailsModule.cs +++ b/src/Sonarr.Api.V3/Tags/TagDetailsModule.cs @@ -13,11 +13,11 @@ namespace Sonarr.Api.V3.Tags { _tagService = tagService; - GetResourceById = Get; + GetResourceById = GetTagDetails; GetResourceAll = GetAll; } - private TagDetailsResource Get(int id) + private TagDetailsResource GetTagDetails(int id) { return _tagService.Details(id).ToResource(); } diff --git a/src/Sonarr.Api.V3/Tags/TagModule.cs b/src/Sonarr.Api.V3/Tags/TagModule.cs index 5aba55881..a0b315d7e 100644 --- a/src/Sonarr.Api.V3/Tags/TagModule.cs +++ b/src/Sonarr.Api.V3/Tags/TagModule.cs @@ -17,14 +17,14 @@ namespace Sonarr.Api.V3.Tags { _tagService = tagService; - GetResourceById = Get; + GetResourceById = GetTag; GetResourceAll = GetAll; CreateResource = Create; UpdateResource = Update; - DeleteResource = Delete; + DeleteResource = DeleteTag; } - private TagResource Get(int id) + private TagResource GetTag(int id) { return _tagService.GetTag(id).ToResource(); } @@ -44,7 +44,7 @@ namespace Sonarr.Api.V3.Tags _tagService.Update(resource.ToModel()); } - private void Delete(int id) + private void DeleteTag(int id) { _tagService.Delete(id); } diff --git a/src/Sonarr.Http/Frontend/Mappers/BackupFileMapper.cs b/src/Sonarr.Http/Frontend/Mappers/BackupFileMapper.cs index 4f37913f1..17027aeab 100644 --- a/src/Sonarr.Http/Frontend/Mappers/BackupFileMapper.cs +++ b/src/Sonarr.Http/Frontend/Mappers/BackupFileMapper.cs @@ -1,7 +1,6 @@ using System.IO; using NLog; using NzbDrone.Common.Disk; -using NzbDrone.Common.EnvironmentInfo; using NzbDrone.Core.Backup; namespace Sonarr.Http.Frontend.Mappers @@ -9,7 +8,6 @@ namespace Sonarr.Http.Frontend.Mappers public class BackupFileMapper : StaticResourceMapperBase { private readonly IBackupService _backupService; - private readonly IAppFolderInfo _appFolderInfo; public BackupFileMapper(IBackupService backupService, IDiskProvider diskProvider, Logger logger) : base(diskProvider, logger) diff --git a/src/Sonarr.Http/TinyIoCNancyBootstrapper.cs b/src/Sonarr.Http/TinyIoCNancyBootstrapper.cs index b0a727209..4944f1a39 100644 --- a/src/Sonarr.Http/TinyIoCNancyBootstrapper.cs +++ b/src/Sonarr.Http/TinyIoCNancyBootstrapper.cs @@ -91,7 +91,6 @@ namespace Sonarr.Http break; case Lifetime.PerRequest: throw new InvalidOperationException("Unable to directly register a per request lifetime."); - break; default: throw new ArgumentOutOfRangeException(); } @@ -118,7 +117,6 @@ namespace Sonarr.Http break; case Lifetime.PerRequest: throw new InvalidOperationException("Unable to directly register a per request lifetime."); - break; default: throw new ArgumentOutOfRangeException(); }