some cleanup

pull/4/head
kay.one 13 years ago
parent edf9d1d2cc
commit b086414d75

@ -23,7 +23,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(true);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(true);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(true);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(true);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(0);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(2);
@ -50,7 +50,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(false);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(true);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(true);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(true);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(0);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(0);
@ -77,7 +77,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(true);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(false);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(false);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(true);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(1);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(1);
@ -104,7 +104,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(true);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(false);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(false);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(false);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(1);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(3);
@ -132,7 +132,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(true);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(true);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(true);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(false);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(1);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(3);
@ -159,7 +159,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(true);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(true);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(true);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(true);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(0);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(3);
@ -186,7 +186,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(false);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(false);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(false);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(false);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(0);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(2);
@ -214,7 +214,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(true);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(true);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(true);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(true);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(0);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(2);
@ -248,7 +248,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(false);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(true);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(true);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(true);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(0);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(0);
@ -282,7 +282,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(false);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(true);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(true);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(true);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(1);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(0);
@ -316,7 +316,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(true);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(true);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(true);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(false);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(1);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(3);
@ -350,7 +350,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(true);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(false);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(false);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(false);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(0);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(2);
@ -384,7 +384,7 @@ namespace NzbDrone.Core.Test
var fakeConfig = mocker.GetMock<ConfigProvider>();
fakeConfig.SetupGet(c => c.SortingIncludeSeriesName).Returns(false);
fakeConfig.SetupGet(c => c.SortingEpisodeName).Returns(false);
fakeConfig.SetupGet(c => c.SortingIncludeEpisodeTitle).Returns(false);
fakeConfig.SetupGet(c => c.SortingAppendQuality).Returns(false);
fakeConfig.SetupGet(c => c.SortingSeparatorStyle).Returns(0);
fakeConfig.SetupGet(c => c.SortingNumberStyle).Returns(0);

@ -197,13 +197,13 @@ namespace NzbDrone.Core.Providers.Core
set { SetValue("BlackholeDirectory", value); }
}
public virtual bool SortingSeriesName
public virtual bool SortingIncludeSeriesName
{
get { return GetValueBoolean("Sorting_SeriesName", true); }
set { SetValue("Sorting_SeriesName", value); }
}
public virtual bool SortingEpisodeName
public virtual bool SortingIncludeEpisodeTitle
{
get { return GetValueBoolean("Sorting_EpisodeName", true); }
set { SetValue("Sorting_EpisodeName", value); }
@ -211,7 +211,7 @@ namespace NzbDrone.Core.Providers.Core
public virtual bool SortingReplaceSpaces
{
get { return GetValueBoolean("Sorting_ReplaceSpaces", true); }
get { return GetValueBoolean("Sorting_ReplaceSpaces"); }
set { SetValue("Sorting_ReplaceSpaces", value); }
}

@ -73,7 +73,7 @@ namespace NzbDrone.Core.Providers.Jobs
var updatedSeries = _seriesProvider.GetSeries(currentSeries.SeriesId);
AutoIgnoreSeasons(updatedSeries.SeriesId);
notification.CurrentMessage = String.Format("'{0}' was successfully imported", currentSeries.Title);
notification.CurrentMessage = String.Format("{0} was successfully imported", updatedSeries.Title);
}
catch (Exception e)

@ -175,7 +175,7 @@ namespace NzbDrone.Core.Providers
.Replace("%x", numberStyle.EpisodeSeparator)
.Replace("%p", separatorStyle.Pattern);
if (_configProvider.SortingEpisodeName)
if (_configProvider.SortingIncludeEpisodeTitle)
{
episodeNames = episodeNames.TrimEnd(' ', '+');
result += separatorStyle.Pattern + episodeNames;

@ -164,7 +164,7 @@ namespace NzbDrone.Web.Controllers
var model = new EpisodeSortingModel();
model.SeriesName = _configProvider.SortingIncludeSeriesName;
model.EpisodeName = _configProvider.SortingEpisodeName;
model.EpisodeName = _configProvider.SortingIncludeEpisodeTitle;
model.ReplaceSpaces = _configProvider.SortingReplaceSpaces;
model.AppendQuality = _configProvider.SortingAppendQuality;
model.SeasonFolders = _configProvider.UseSeasonFolder;
@ -436,7 +436,7 @@ namespace NzbDrone.Web.Controllers
if (ModelState.IsValid)
{
_configProvider.SortingIncludeSeriesName = data.SeriesName;
_configProvider.SortingEpisodeName = data.EpisodeName;
_configProvider.SortingIncludeEpisodeTitle = data.EpisodeName;
_configProvider.SortingReplaceSpaces = data.ReplaceSpaces;
_configProvider.SortingAppendQuality = data.AppendQuality;
_configProvider.UseSeasonFolder = data.SeasonFolders;

Loading…
Cancel
Save