Skip to content

Commit

Permalink
fix the fingerprint generation (#1432)
Browse files Browse the repository at this point in the history
  • Loading branch information
vedhavyas authored Aug 20, 2020
1 parent 59b182b commit b0073bd
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion documents/coredocument.go
Original file line number Diff line number Diff line change
Expand Up @@ -512,7 +512,13 @@ func generateTransitionRulesFingerprintHash(fingerprint coredocumentpb.Transitio
return nil, err
}

return sha3.NewLegacyKeccak256().Sum(fm), nil
s := sha3.NewLegacyKeccak256()
_, err = s.Write(fm)
if err != nil {
return nil, err
}

return s.Sum(nil), nil
}

// TODO remove as soon as we have a public method that retrieves the parent prefix
Expand Down

0 comments on commit b0073bd

Please sign in to comment.