mirror of
https://github.com/Radarr/Radarr
synced 2026-01-06 15:43:19 +01:00
Fixed: Skip move when source and destination are the same
Co-Authored-By: Colin Hebert <makkhdyn@gmail.com>
This commit is contained in:
parent
ae8820178d
commit
7a5ae56a96
1 changed files with 7 additions and 0 deletions
|
|
@ -1,6 +1,7 @@
|
|||
using System.IO;
|
||||
using NLog;
|
||||
using NzbDrone.Common.Disk;
|
||||
using NzbDrone.Common.Extensions;
|
||||
using NzbDrone.Common.Instrumentation.Extensions;
|
||||
using NzbDrone.Core.Messaging.Commands;
|
||||
using NzbDrone.Core.Messaging.Events;
|
||||
|
|
@ -51,6 +52,12 @@ private void MoveSingleMovie(Movie movie, string sourcePath, string destinationP
|
|||
_logger.ProgressInfo("Moving {0} from '{1}' to '{2}'", movie.Title, sourcePath, destinationPath);
|
||||
}
|
||||
|
||||
if (sourcePath.PathEquals(destinationPath))
|
||||
{
|
||||
_logger.ProgressInfo("{0} is already in the specified location '{1}'.", movie, destinationPath);
|
||||
return;
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
_diskProvider.CreateFolder(new DirectoryInfo(destinationPath).Parent.FullName);
|
||||
|
|
|
|||
Loading…
Reference in a new issue