Skip to content

Commit

Permalink
fix: nil pointer
Browse files Browse the repository at this point in the history
  • Loading branch information
PhearZero committed Oct 21, 2024
1 parent 724938f commit bd15066
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/accounts.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ type Account struct {
// AccountsFromParticipationKeys maps an array of api.ParticipationKey to a keyed map of Account
func AccountsFromState(state *StateModel) map[string]Account {
values := make(map[string]Account)
if state == nil {
if state == nil || state.ParticipationKeys == nil {
return values
}
for _, key := range *state.ParticipationKeys {
Expand Down

0 comments on commit bd15066

Please sign in to comment.