Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Rename saveResult to reportResult method

  • Loading branch information...
commit f6e2a095b3dcbcffdd069a4c2e264ab4104c6635 1 parent fbc011e
@c9s authored
View
2  src/ValidationKit/CallbackValidator.php
@@ -16,7 +16,7 @@ public function __construct($callbackArgs)
public function validate($value)
{
$ret = call_user_func_array( $this->callbackArgs , array($value) );
- return $this->saveResult( $ret );
+ return $this->reportResult( $ret );
}
}
View
8 src/ValidationKit/Validator.php
@@ -51,14 +51,14 @@ public function __construct($options = array(), $msgstrs = array())
/**
* Save validate result (success or fail)
*
- * @param boolean $result success or fail
- * @param integer $code code of message
+ * @param boolean $valid success or fail
+ * @param string $msgId code of message
*
* @return boolean success or failed.
*/
- protected function saveResult($result,$msgId = null)
+ protected function reportResult($valid,$msgId = null)
{
- if( $result ) {
+ if( $valid ) {
return $this->valid($msgId);
} else {
return $this->invalid($msgId);
Please sign in to comment.
Something went wrong with that request. Please try again.