Reference property via `nameof` rather than hardcoding

This commit is contained in:
Bartłomiej Dach 2024-01-09 11:49:42 +01:00
parent cac0b0de6d
commit a8a70be04a
No known key found for this signature in database
1 changed files with 1 additions and 1 deletions

View File

@ -98,7 +98,7 @@ public void Cleanup()
// can potentially be run asynchronously, although we will need to consider operation order for disk deletion vs realm removal.
realm.Write(r =>
{
foreach (var file in r.All<RealmFile>().Filter("Usages.@count = 0"))
foreach (var file in r.All<RealmFile>().Filter(@$"{nameof(RealmFile.Usages)}.@count = 0"))
{
totalFiles++;