@@ -297,7 +297,7 @@ discard block |
||
| 297 | 297 | } |
| 298 | 298 | |
| 299 | 299 | /** |
| 300 | - * @param $exceptionClass |
|
| 300 | + * @param string $exceptionClass |
|
| 301 | 301 | * @return Assert |
| 302 | 302 | */ |
| 303 | 303 | public function setExceptionClass($exceptionClass) |
@@ -1353,7 +1353,7 @@ discard block |
||
| 1353 | 1353 | /** |
| 1354 | 1354 | * Alias of {@see choice()} |
| 1355 | 1355 | * |
| 1356 | - * @param array $choices |
|
| 1356 | + * @param integer[] $choices |
|
| 1357 | 1357 | * @param string|null $message |
| 1358 | 1358 | * @param string|null $fieldName |
| 1359 | 1359 | * @return Assert |
@@ -2593,7 +2593,7 @@ discard block |
||
| 2593 | 2593 | } |
| 2594 | 2594 | |
| 2595 | 2595 | /** |
| 2596 | - * @param $func |
|
| 2596 | + * @param string $func |
|
| 2597 | 2597 | * @param $args |
| 2598 | 2598 | * @return bool |
| 2599 | 2599 | * @throws AssertionFailedException |
@@ -157,8 +157,7 @@ discard block |
||
| 157 | 157 | try |
| 158 | 158 | { |
| 159 | 159 | $validator->__invoke(); |
| 160 | - } |
|
| 161 | - catch ( AssertionFailedException $e ) |
|
| 160 | + } catch ( AssertionFailedException $e ) |
|
| 162 | 161 | { |
| 163 | 162 | $errors[$fieldName] = $e->getMessage(); |
| 164 | 163 | } |
@@ -2079,8 +2078,7 @@ discard block |
||
| 2079 | 2078 | $this->stringify($this->value) |
| 2080 | 2079 | ); |
| 2081 | 2080 | throw $this->createException($message, $this->overrideCode ?: self::INVALID_EMAIL, $fieldName); |
| 2082 | - } |
|
| 2083 | - else |
|
| 2081 | + } else |
|
| 2084 | 2082 | { |
| 2085 | 2083 | $host = substr($this->value, strpos($this->value, '@') + 1); |
| 2086 | 2084 | // Likely not a FQDN, bug in PHP FILTER_VALIDATE_EMAIL prior to PHP 5.3.3 |
@@ -2208,8 +2206,7 @@ discard block |
||
| 2208 | 2206 | try |
| 2209 | 2207 | { |
| 2210 | 2208 | $this->regex('/^04[0-9]{8})$/', $message, $fieldName); |
| 2211 | - } |
|
| 2212 | - catch ( AssertionFailedException $e ) |
|
| 2209 | + } catch ( AssertionFailedException $e ) |
|
| 2213 | 2210 | { |
| 2214 | 2211 | $message = $message ?: $this->overrideError; |
| 2215 | 2212 | $message = sprintf( |
@@ -2239,8 +2236,7 @@ discard block |
||
| 2239 | 2236 | try |
| 2240 | 2237 | { |
| 2241 | 2238 | $this->regex('(^([a-zA-Z]{1}[a-zA-Z0-9]*)$)', $message, $fieldName); |
| 2242 | - } |
|
| 2243 | - catch (AssertionFailedException $e) |
|
| 2239 | + } catch (AssertionFailedException $e) |
|
| 2244 | 2240 | { |
| 2245 | 2241 | $message = $message ?: $this->overrideError; |
| 2246 | 2242 | $message = sprintf( |
@@ -2528,8 +2524,7 @@ discard block |
||
| 2528 | 2524 | try |
| 2529 | 2525 | { |
| 2530 | 2526 | $this->email($message, $fieldName); |
| 2531 | - } |
|
| 2532 | - catch (AssertionFailedException $e) |
|
| 2527 | + } catch (AssertionFailedException $e) |
|
| 2533 | 2528 | { |
| 2534 | 2529 | $message = $message ?: $this->overrideError; |
| 2535 | 2530 | $message = sprintf( |