@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | * Return a variable with some basic treatment |
96 | 96 | * |
97 | 97 | * @param mixed $varToSanitize The variable we want to treat for future use |
98 | - * @param mixed $varDefaultValue The default value to set to the variable if the different test are not successfull |
|
98 | + * @param string $varDefaultValue The default value to set to the variable if the different test are not successfull |
|
99 | 99 | * @param string $varType optionnal The type of the var for better verification |
100 | 100 | * |
101 | 101 | * @return mixed $sanitizedVar The var after treatment |
@@ -223,6 +223,7 @@ discard block |
||
223 | 223 | * Return unit sigle |
224 | 224 | * @param unknown_type $code |
225 | 225 | * @param unknown_type $column_to_return |
226 | + * @return string |
|
226 | 227 | */ |
227 | 228 | public static function wpshop_get_sigle($code, $column_to_return = "unit") { |
228 | 229 | $tmp_code = (int)$code; |
@@ -253,7 +254,7 @@ discard block |
||
253 | 254 | /** |
254 | 255 | * Check if string have phone number structure |
255 | 256 | * @param string phone number |
256 | - * @return boolean |
|
257 | + * @return integer |
|
257 | 258 | */ |
258 | 259 | public static function is_phone( $phone ) { |
259 | 260 | return preg_match( '/(?=.*[0-9])([ 0-9\-\+\(\)]+)/', $phone ); |
@@ -262,7 +263,7 @@ discard block |
||
262 | 263 | /** |
263 | 264 | * Check if string have postcode valid structure |
264 | 265 | * @param string postcode |
265 | - * @return boolean |
|
266 | + * @return integer |
|
266 | 267 | */ |
267 | 268 | public static function is_postcode( $postcode ) { |
268 | 269 | return preg_match( '/(?=.*[0-9A-Za-z])([ \-A-Za-z0-9]+)/', $postcode ); |
@@ -321,7 +322,7 @@ discard block |
||
321 | 322 | * Transform a given text with a specific pattern, send by the second parameter |
322 | 323 | * |
323 | 324 | * @param string $toSlugify The string we want to "clean" for future use |
324 | - * @param array|string $slugifyType The type of cleaning we are going to do on the input text |
|
325 | + * @param string[] $slugifyType The type of cleaning we are going to do on the input text |
|
325 | 326 | * |
326 | 327 | * @return string $slugified The input string that was slugified with the selected method |
327 | 328 | */ |