diff --git a/src/FileMigrationHelper.php b/src/FileMigrationHelper.php index 5cfa3b0d..8a25fcb8 100644 --- a/src/FileMigrationHelper.php +++ b/src/FileMigrationHelper.php @@ -168,7 +168,11 @@ protected function migrateFile($base, File $file, $legacyFilename) if (!$useLegacyFilenames) { // removing the legacy file since it has been migrated now and not using legacy filenames - return unlink($path); + $removed = unlink($path); + if (!$removed) { + $this->logger->warning("$legacyFilename was migrated, but failed to remove the legacy file ($path)"); + } + return $removed; } return true; }