Skip to content

Commit

Permalink
Fix ReSharper's "Use string interpolation expression" and "Replace if…
Browse files Browse the repository at this point in the history
… statement with null-propagating code" / Code Smell (#240)
  • Loading branch information
marodev authored May 21, 2021
1 parent bde2663 commit 5321cec
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
2 changes: 1 addition & 1 deletion dropbox-sdk-dotnet/Dropbox.Api/DropboxAppClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ private static string GetBasicAuthHeader(string appKey, string appSecret)
throw new ArgumentNullException("appSecret");
}

var rawValue = string.Format("{0}:{1}", appKey, appSecret);
var rawValue = $"{appKey}:{appSecret}";
return Convert.ToBase64String(Encoding.UTF8.GetBytes(rawValue));
}
}
Expand Down
5 changes: 1 addition & 4 deletions dropbox-sdk-dotnet/Dropbox.Api/DropboxRequestHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -430,10 +430,7 @@ private async Task<Result> RequestJsonStringWithRetry(
}
finally
{
if (body != null)
{
body.Dispose();
}
body?.Dispose();
}
}

Expand Down

0 comments on commit 5321cec

Please sign in to comment.