Commit 56f74b37 authored by Koen van Ingen's avatar Koen van Ingen
Browse files

error handling

parent 0026bf71
......@@ -317,9 +317,15 @@ func (sr *SignatureRequest) UnmarshalJSON(b []byte) error {
type SignatureRequestTemp SignatureRequest // To avoid 'recursive unmarshalling'
fixedRequest, err := convertFieldsToBigInt(b, []string{"nonce", "context"})
if err != nil {
return err
var result SignatureRequestTemp
json.Unmarshal(fixedRequest, &result)
err = json.Unmarshal(fixedRequest, &result)
if err != nil {
return err
sr.DisclosureRequest = result.DisclosureRequest
sr.Message = result.Message
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment