Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,8 @@ dotnet_diagnostic.RCS1264.severity = none
dotnet_diagnostic.IDE0011.severity = warning
# Use collection initializers or expressions.
dotnet_diagnostic.IDE0028.severity = warning
# Use null propagation.
dotnet_diagnostic.IDE0031.severity = warning # Note: There is some overlap with RCS1146.
Comment thread
glen-84 marked this conversation as resolved.
# Order modifiers.
dotnet_diagnostic.IDE0036.severity = warning
# Use inferred member names.
Expand Down Expand Up @@ -295,9 +297,8 @@ dotnet_diagnostic.RCS1097.severity = warning
# Mark local variable as const.
dotnet_diagnostic.RCS1118.severity = warning
# Use conditional access.
dotnet_diagnostic.RCS1146.severity = warning
dotnet_diagnostic.RCS1146.severity = warning # Note: There is some overlap with IDE0031.
roslynator_null_conditional_operator.avoid_negative_boolean_comparison = true
dotnet_diagnostic.IDE0031.severity = none
# Abstract type should not have public constructors.
dotnet_diagnostic.RCS1160.severity = warning
# Unused parameter.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,11 +103,9 @@ public async ValueTask DisposeAsync()
_disposed = true;
await _clientScope.DisposeAsync();

if (_pool is not null)
{
_pool.Return(this);
_pool = null;
}
var pool = _pool;
_pool = null;
pool?.Return(this);
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,7 @@ private async Task ListenAsync(CancellationToken cancellationToken)
}
finally
{
if (_connection is not null)
{
_connection.Notification -= OnNotification;
}
_connection?.Notification -= OnNotification;
}
}

Expand Down
Loading