[backend/drive] Fix drive file cleanup job for locally stored files
This commit is contained in:
parent
fd7d3eabb2
commit
75042fc5d5
1 changed files with 3 additions and 2 deletions
|
@ -437,7 +437,8 @@ public class DriveService(
|
|||
{
|
||||
if (file is not { UserHost: not null, Uri: not null, IsLink: false }) return;
|
||||
|
||||
string?[] paths = [file.AccessKey, file.ThumbnailAccessKey, file.PublicAccessKey];
|
||||
string?[] paths = [file.AccessKey, file.ThumbnailAccessKey, file.PublicAccessKey];
|
||||
var storedInternal = file.StoredInternal;
|
||||
|
||||
file.IsLink = true;
|
||||
file.Url = file.Uri;
|
||||
|
@ -465,7 +466,7 @@ public class DriveService(
|
|||
return;
|
||||
}
|
||||
|
||||
if (file.StoredInternal)
|
||||
if (storedInternal)
|
||||
{
|
||||
var pathBase = storageConfig.Value.Local?.Path ??
|
||||
throw new Exception("Cannot delete locally stored file: pathBase is null");
|
||||
|
|
Loading…
Add table
Reference in a new issue