[backend/drive] Correctly set thumbnail & webpublicUrl when using the local storage provider
This commit is contained in:
parent
facc7eb337
commit
7976854190
1 changed files with 2 additions and 0 deletions
|
@ -246,6 +246,7 @@ public class DriveService(
|
||||||
await using var thumbWriter = File.OpenWrite(thumbPath);
|
await using var thumbWriter = File.OpenWrite(thumbPath);
|
||||||
await thumbnail.CopyToAsync(thumbWriter);
|
await thumbnail.CopyToAsync(thumbWriter);
|
||||||
await thumbnail.DisposeAsync();
|
await thumbnail.DisposeAsync();
|
||||||
|
thumbnailUrl = $"https://{instanceConfig.Value.WebDomain}/files/{thumbnailFilename}";
|
||||||
}
|
}
|
||||||
|
|
||||||
if (webpublicFilename != null && webpublic is { Length: > 0 })
|
if (webpublicFilename != null && webpublic is { Length: > 0 })
|
||||||
|
@ -254,6 +255,7 @@ public class DriveService(
|
||||||
await using var webpWriter = File.OpenWrite(webpPath);
|
await using var webpWriter = File.OpenWrite(webpPath);
|
||||||
await webpublic.CopyToAsync(webpWriter);
|
await webpublic.CopyToAsync(webpWriter);
|
||||||
await webpublic.DisposeAsync();
|
await webpublic.DisposeAsync();
|
||||||
|
webpublicUrl = $"https://{instanceConfig.Value.WebDomain}/files/{webpublicFilename}";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Add table
Reference in a new issue