Merge PR #3806: Fix nil returned in Unmarshal functions
* Fix nils returned in unmarshal functions * Address comments
This commit is contained in:
committed by
Christopher Goes
parent
dcc3357ea3
commit
805e7fbfc2
+2
-2
@@ -279,7 +279,7 @@ func (va *ValAddress) UnmarshalJSON(data []byte) error {
|
||||
|
||||
err := json.Unmarshal(data, &s)
|
||||
if err != nil {
|
||||
return nil
|
||||
return err
|
||||
}
|
||||
|
||||
va2, err := ValAddressFromBech32(s)
|
||||
@@ -415,7 +415,7 @@ func (ca *ConsAddress) UnmarshalJSON(data []byte) error {
|
||||
|
||||
err := json.Unmarshal(data, &s)
|
||||
if err != nil {
|
||||
return nil
|
||||
return err
|
||||
}
|
||||
|
||||
ca2, err := ConsAddressFromBech32(s)
|
||||
|
||||
Reference in New Issue
Block a user