mirror of
https://github.com/Caraxi/mare.server.git
synced 2025-12-12 19:57:23 +01:00
fix file cleanup removing db entries currently in upload
This commit is contained in:
parent
d08e5f9c04
commit
769f52b8a5
2 changed files with 2 additions and 1 deletions
|
|
@ -60,7 +60,7 @@ namespace MareSynchronosServer
|
|||
File.Delete(fileName);
|
||||
}
|
||||
}
|
||||
var allFiles = dbContext.Files;
|
||||
var allFiles = dbContext.Files.Where(f => f.Uploaded);
|
||||
foreach (var file in allFiles)
|
||||
{
|
||||
var fileName = Path.Combine(_configuration["CacheDirectory"], file.Hash);
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
<PropertyGroup>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<UserSecretsId>aspnet-MareSynchronosServer-BA82A12A-0B30-463C-801D-B7E81318CD50</UserSecretsId>
|
||||
<AssemblyVersion>1.1.0.0</AssemblyVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue