[PHP] - Removes trailing comma from ::flattenArray() (#20988)

* [PHP] - Removes trailing comma from ::flattenArray()

* Removes "mixed" type

* Missed one mixed
This commit is contained in:
Juan Treminio 2025-03-29 12:08:52 -05:00 committed by GitHub
parent 5e5832d982
commit c6e2a5fa94
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 9 additions and 9 deletions

View File

@ -324,7 +324,7 @@ class ObjectSerializer
* *
* @return array [key => value] of formdata * @return array [key => value] of formdata
*/ */
public static function toFormValue(string $key, mixed $value) public static function toFormValue(string $key, $value)
{ {
if ($value instanceof \SplFileObject) { if ($value instanceof \SplFileObject) {
return [$key => $value->getRealPath()]; return [$key => $value->getRealPath()];
@ -628,9 +628,9 @@ class ObjectSerializer
* credit: https://github.com/FranBar1966/FlatPHP * credit: https://github.com/FranBar1966/FlatPHP
*/ */
private static function flattenArray( private static function flattenArray(
mixed $source, $source,
array &$destination, array &$destination,
string $start = '', string $start = ''
) { ) {
$opt = [ $opt = [
'prefix' => '[', 'prefix' => '[',

View File

@ -333,7 +333,7 @@ class ObjectSerializer
* *
* @return array [key => value] of formdata * @return array [key => value] of formdata
*/ */
public static function toFormValue(string $key, mixed $value) public static function toFormValue(string $key, $value)
{ {
if ($value instanceof \SplFileObject) { if ($value instanceof \SplFileObject) {
return [$key => $value->getRealPath()]; return [$key => $value->getRealPath()];
@ -637,9 +637,9 @@ class ObjectSerializer
* credit: https://github.com/FranBar1966/FlatPHP * credit: https://github.com/FranBar1966/FlatPHP
*/ */
private static function flattenArray( private static function flattenArray(
mixed $source, $source,
array &$destination, array &$destination,
string $start = '', string $start = ''
) { ) {
$opt = [ $opt = [
'prefix' => '[', 'prefix' => '[',

View File

@ -333,7 +333,7 @@ class ObjectSerializer
* *
* @return array [key => value] of formdata * @return array [key => value] of formdata
*/ */
public static function toFormValue(string $key, mixed $value) public static function toFormValue(string $key, $value)
{ {
if ($value instanceof \SplFileObject) { if ($value instanceof \SplFileObject) {
return [$key => $value->getRealPath()]; return [$key => $value->getRealPath()];
@ -637,9 +637,9 @@ class ObjectSerializer
* credit: https://github.com/FranBar1966/FlatPHP * credit: https://github.com/FranBar1966/FlatPHP
*/ */
private static function flattenArray( private static function flattenArray(
mixed $source, $source,
array &$destination, array &$destination,
string $start = '', string $start = ''
) { ) {
$opt = [ $opt = [
'prefix' => '[', 'prefix' => '[',