Use phpstan-specific comments for main sanitization + validation

functions
This commit is contained in:
Joshua Ramon Enslin 2024-01-14 22:18:48 +01:00
parent 69e6850c16
commit 2bea372973
Signed by: jrenslin
GPG Key ID: 46016F84501B70AE

View File

@ -14,7 +14,7 @@ final class MD_STD_IN {
*
* @param mixed $input Input string.
*
* @return integer
* @return positive-int
*/
public static function sanitize_id(mixed $input):int {
@ -39,7 +39,7 @@ final class MD_STD_IN {
*
* @param mixed $input Input string.
*
* @return integer
* @return 0|positive-int
*/
public static function sanitize_id_or_zero(mixed $input):int {
@ -92,7 +92,7 @@ final class MD_STD_IN {
*
* @param mixed $input Input string.
*
* @return string
* @return non-empty-string
*/
public static function sanitize_rgb_color(mixed $input):string {
@ -117,7 +117,7 @@ final class MD_STD_IN {
*
* @param array<mixed> $inputs Input array.
*
* @return list<integer>
* @return list<positive-int>
*/
public static function sanitize_id_array(array $inputs):array {