Permalink
Browse files

some doc block corrections as well a !! to (bool) convertion

remove nonsense default value
  • Loading branch information...
1 parent 5870d71 commit 18fb132d41fe9f0e406217fd9d92b4bab1aa256a @dereuromark dereuromark committed Nov 22, 2012
Showing with 5 additions and 5 deletions.
  1. +1 −1 lib/Cake/Utility/Folder.php
  2. +2 −2 lib/Cake/Utility/Set.php
  3. +2 −2 lib/Cake/Utility/Validation.php
@@ -634,7 +634,7 @@ public function delete($path = null) {
* @return boolean Success
* @link http://book.cakephp.org/2.0/en/core-utility-libraries/file-folder.html#Folder::copy
*/
- public function copy($options = array()) {
+ public function copy($options) {
if (!$this->pwd()) {
return false;
}
View
@@ -203,7 +203,7 @@ public static function numeric($array = null) {
*
* $list defaults to 0 = no 1 = yes if param is not passed
*
- * @param array $select Key in $list to return
+ * @param string $select Key in $list to return
* @param array|string $list can be an array or a comma-separated list.
* @return string the value of the array key or null if no match
* @link http://book.cakephp.org/2.0/en/core-utility-libraries/set.html#Set::enum
@@ -467,7 +467,7 @@ public static function matches($conditions, $data = array(), $i = null, $length
return true;
}
if (is_string($conditions)) {
- return !!Set::extract($conditions, $data);
+ return (bool)Set::extract($conditions, $data);
}
foreach ($conditions as $condition) {
if ($condition === ':last') {
@@ -321,7 +321,7 @@ public static function date($check, $format = 'ymd', $regex = null) {
* Validates a datetime value
* All values matching the "date" core validation rule, and the "time" one will be valid
*
- * @param array $check Value to check
+ * @param string $check Value to check
* @param string|array $dateFormat Format of the date part
* Use a string or an array of the keys below. Arrays should be passed as array('dmy', 'mdy', etc)
* ## Keys:
@@ -381,7 +381,7 @@ public static function boolean($check) {
* - true => Any number of decimal places greater than 0, or a float|double. The '.' is required.
* - 1..N => Exactly that many number of decimal places. The '.' is required.
*
- * @param integer $check The value the test for decimal
+ * @param float $check The value the test for decimal
* @param integer $places
* @param string $regex If a custom regular expression is used, this is the only validation that will occur.
* @return boolean Success

0 comments on commit 18fb132

Please sign in to comment.