Skip to content

Commit

Permalink
chore: returning errors
Browse files Browse the repository at this point in the history
  • Loading branch information
AllanCapistrano committed Sep 17, 2023
1 parent bcf5b2a commit 2d3058b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion messages/getAllMessagesByIndex.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ func formatMessagePayload(message iotago.Message, messageIndex string) (Message,
index = payloadTemp[1]
content = payloadTemp[2]
} else {
log.Panic("Unexpected array length.")
return Message{}, errors.New("unexpected array length")
}
} else if strings.Contains(payloadInString, "\t") {
payloadTemp := strings.Split(payloadInString, "\t")
Expand Down

0 comments on commit 2d3058b

Please sign in to comment.