mirror of
https://github.com/Sonarr/Sonarr
synced 2024-12-29 11:16:19 +00:00
cleanup series path on update.
This commit is contained in:
parent
af1d7b0e80
commit
1c62782fcd
1 changed files with 12 additions and 0 deletions
|
@ -1,4 +1,5 @@
|
||||||
using System;
|
using System;
|
||||||
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using NLog;
|
using NLog;
|
||||||
using NzbDrone.Common.Messaging;
|
using NzbDrone.Common.Messaging;
|
||||||
|
@ -82,6 +83,17 @@ namespace NzbDrone.Core.Tv
|
||||||
series.SeriesType = SeriesTypes.Daily;
|
series.SeriesType = SeriesTypes.Daily;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
|
series.Path = new DirectoryInfo(series.Path).FullName;
|
||||||
|
series.Path = series.Path.GetActualCasing();
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
_logger.WarnException("Couldn't update series path for " + series.Path, e);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
_seriesService.UpdateSeries(series);
|
_seriesService.UpdateSeries(series);
|
||||||
|
|
||||||
_refreshEpisodeService.RefreshEpisodeInfo(series, tuple.Item2);
|
_refreshEpisodeService.RefreshEpisodeInfo(series, tuple.Item2);
|
||||||
|
|
Loading…
Reference in a new issue