update CheckPassword

This commit is contained in:
regnersen 2024-01-14 02:36:23 +07:00
parent a1e5a1092b
commit b3d38cabb9

View file

@ -43,15 +43,11 @@ func (storage BlockchainStorage) Delete(id string) (err error) {
func (storage BlockchainStorage) CheckPassword(id string, secret util.Uint256) (bool, error) {
_, err := storage.contract.CheckUser(id, secret)
if err == nil {
return true, nil
if err != nil {
return false, err
}
if err.Error() == "Password hashes does not match" {
return false, nil
}
return false, err
return true, nil
}
func main() {