Skip to content

Commit

Permalink
review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
ak88 committed May 23, 2024
1 parent d366187 commit 281f35d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public AddRangeResult AddAccountRange(AccountRange request, AccountsAndProofs re
{
AddRangeResult result;

if (!response.PathAndAccounts.Any())
if (response.PathAndAccounts.Count == 0)
{
_logger.Trace($"SNAP - GetAccountRange - requested expired RootHash:{request.RootHash}");

Expand Down Expand Up @@ -87,7 +87,7 @@ public AddRangeResult AddAccountRange(
IReadOnlyList<byte[]> proofs = null,
in ValueHash256? hashLimit = null!)
{
if (!accounts.Any())
if (accounts.Count == 0)
throw new ArgumentException("Cannot be empty.", nameof(accounts));
ITrieStore store = _trieStorePool.Get();
try
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public static (AddRangeResult result, bool moreChildrenToRight, List<PathWithAcc
)
{
// TODO: Check the accounts boundaries and sorting
if (!accounts.Any())
if (accounts.Count == 0)
throw new ArgumentException("Cannot be empty.", nameof(accounts));
ValueHash256 lastHash = accounts[^1].Path;

Expand Down

0 comments on commit 281f35d

Please sign in to comment.