Skip to content

Commit e7c292d

Browse files
authored
Fix: Fixed NullReferenceException in RecycleBinLocationItem.RefreshSpaceUsed (#15933)
1 parent 69a02f1 commit e7c292d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Files.App/Data/Items/LocationItem.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -124,9 +124,9 @@ public int CompareTo(INavigationControlItem other)
124124

125125
public sealed class RecycleBinLocationItem : LocationItem
126126
{
127-
public void RefreshSpaceUsed(object sender, FileSystemEventArgs e)
127+
public async void RefreshSpaceUsed(object sender, FileSystemEventArgs e)
128128
{
129-
MainWindow.Instance.DispatcherQueue.TryEnqueue(() =>
129+
await MainWindow.Instance.DispatcherQueue.EnqueueOrInvokeAsync(() =>
130130
{
131131
SpaceUsed = RecycleBinHelpers.GetSize();
132132
});

0 commit comments

Comments
 (0)