Explicitly expect positive ints for depths in MD_STD::json_encode
This commit is contained in:
		| @@ -234,7 +234,7 @@ final class MD_STD { | ||||
|      * | ||||
|      * @param array<mixed> $value   The value being encoded. Can be any type except a resource. | ||||
|      * @param integer      $options Bitmask consisting of JSON_FORCE_OBJECT, JSON_HEX_QUOT ... | ||||
|      * @param integer      $depth   Depth of coding. | ||||
|      * @param positive-int $depth   Depth of coding. | ||||
|      * | ||||
|      * @return string | ||||
|      */ | ||||
| @@ -253,9 +253,9 @@ final class MD_STD { | ||||
|      * | ||||
|      * @see https://www.php.net/manual/en/function.json-encode.php | ||||
|      * | ||||
|      * @param object  $value   The value being encoded. Can be any type except a resource. | ||||
|      * @param integer $options Bitmask consisting of JSON_FORCE_OBJECT, JSON_HEX_QUOT ... | ||||
|      * @param integer $depth   Depth of coding. | ||||
|      * @param object       $value   The value being encoded. Can be any type except a resource. | ||||
|      * @param integer      $options Bitmask consisting of JSON_FORCE_OBJECT, JSON_HEX_QUOT ... | ||||
|      * @param positive-int $depth   Depth of coding. | ||||
|      * | ||||
|      * @return string | ||||
|      */ | ||||
|   | ||||
		Reference in New Issue
	
	Block a user