[FIX] Address Validation in user class

This commit is contained in:
Sebastian Grewe 2014-02-02 11:10:18 +01:00
parent c00b6d6757
commit e59d3a8e25

View File

@ -428,14 +428,8 @@ class User extends Base {
return false; return false;
} }
if ($this->bitcoin->can_connect() === true) { if ($this->bitcoin->can_connect() === true) {
try { if (!$this->bitcoin->validateaddress($address)) {
$aStatus = $this->bitcoin->validateaddress($address); $this->setErrorMessage('Invalid coin address');
if (!$aStatus['isvalid']) {
$this->setErrorMessage('Invalid coin address');
return false;
}
} catch (Exception $e) {
$this->setErrorMessage('Unable to verify coin address');
return false; return false;
} }
} else { } else {