1 | <?php |
||
7 | class Validate extends \Validate { |
||
8 | |||
9 | # Validate string using regex and length limitors |
||
10 | |||
11 | private static function string(string $string, string $regex, int $min, int $max) { |
||
17 | |||
18 | # Validate auth code |
||
19 | |||
20 | public static function authCode(string $value) { |
||
24 | |||
25 | # Validate user name |
||
26 | |||
27 | public static function userName(string $value) { |
||
33 | |||
34 | # Validate user password |
||
35 | |||
36 | public static function userPassword(string $value) { |
||
42 | |||
43 | # Validate user email |
||
44 | |||
45 | public static function userEmail(string $value) { |
||
49 | |||
50 | # Validate file or directory name |
||
51 | |||
52 | public static function fileName(string $value) { |
||
56 | |||
57 | # Validate url |
||
58 | |||
59 | public static function url(string $value) { |
||
69 | } |
||
70 | } |
||
71 |
This check marks access to variables or properties that have not been declared yet. While PHP has no explicit notion of declaring a variable, accessing it before a value is assigned to it is most likely a bug.