diff --git a/rpc/getAccountInfo.go b/rpc/getAccountInfo.go index d9be3b09..2e6dbedc 100644 --- a/rpc/getAccountInfo.go +++ b/rpc/getAccountInfo.go @@ -124,7 +124,7 @@ func (cl *Client) GetAccountInfoWithOpts( if err != nil { return nil, err } - if out.Value == nil { + if out == nil || out.Value == nil { return nil, ErrNotFound } diff --git a/rpc/getMultipleAccounts.go b/rpc/getMultipleAccounts.go index af316cf9..cd88d145 100644 --- a/rpc/getMultipleAccounts.go +++ b/rpc/getMultipleAccounts.go @@ -74,7 +74,7 @@ func (cl *Client) GetMultipleAccountsWithOpts( if err != nil { return nil, err } - if out.Value == nil { + if out == nil || out.Value == nil { return nil, ErrNotFound } return