Skip to content

Commit a953a3e

Browse files
committed
revert to old c# specs
1 parent d97171d commit a953a3e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Sharpnado.TaskLoaderView/TaskLoaderNotifierBase.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ public Exception Error
167167

168168
public TimeSpan AutoResetDelay { get; }
169169

170-
protected object SyncRoot { get; } = new();
170+
protected object SyncRoot { get; } = new object();
171171

172172
public abstract void Load(bool isRefreshing = false);
173173

Sharpnado.TaskLoaderView/TaskLoaderNotifier{T}.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ protected override void OnTaskSuccessfullyCompleted(ITaskMonitor task)
135135
InternalLogger.Debug(Tag, () => "OnTaskSuccessfullyCompleted()");
136136
RaisePropertyChanged(nameof(IsSuccessfullyCompleted));
137137

138-
if (!DisableEmptyState && (Result is null or ICollection { Count: 0 }))
138+
if (!DisableEmptyState && (Result == null || (Result is ICollection collection && collection.Count == 0)))
139139
{
140140
InternalLogger.Debug(Tag, () => "Showing empty state");
141141
ShowEmptyState = true;

0 commit comments

Comments
 (0)