mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Merge pull request #6 from kamilwylegala/3-deprecation-countable
Fixed deprecation notice in PHP 8.1: Countable #3
This commit is contained in:
commit
257f639606
2 changed files with 2 additions and 2 deletions
|
@ -523,7 +523,7 @@ class ModelValidator implements ArrayAccess, IteratorAggregate, Countable {
|
||||||
*
|
*
|
||||||
* @return int
|
* @return int
|
||||||
*/
|
*/
|
||||||
public function count() {
|
public function count() : int {
|
||||||
$this->_parseRules();
|
$this->_parseRules();
|
||||||
return count($this->_fields);
|
return count($this->_fields);
|
||||||
}
|
}
|
||||||
|
|
|
@ -363,7 +363,7 @@ class CakeValidationSet implements ArrayAccess, IteratorAggregate, Countable {
|
||||||
*
|
*
|
||||||
* @return int
|
* @return int
|
||||||
*/
|
*/
|
||||||
public function count() {
|
public function count() : int {
|
||||||
return count($this->_rules);
|
return count($this->_rules);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue