Skip to content

Commit

Permalink
fix: Engine uses OrderedKeys which can be empty
Browse files Browse the repository at this point in the history
  • Loading branch information
skibitsky committed Nov 24, 2023
1 parent e7b0a94 commit 7903fab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion WalletConnectSharp.Sign/Engine.cs
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,7 @@ public async Task<TR> Request<T, TR>(string topic, T data, string chainId = null
if (string.IsNullOrWhiteSpace(chainId))
{
var sessionData = Client.Session.Get(topic);
var firstRequiredNamespace = sessionData.RequiredNamespaces.OrderedKeys[0];
var firstRequiredNamespace = sessionData.RequiredNamespaces.Keys.First();
defaultChainId = sessionData.RequiredNamespaces[firstRequiredNamespace].Chains[0];
}
else
Expand Down

0 comments on commit 7903fab

Please sign in to comment.