Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

namespace {{invokerPackage}};

use BackedEnum;
use DateTimeInterface;
use DateTime;
use GuzzleHttp\Psr7\Utils;
Expand Down Expand Up @@ -254,6 +255,11 @@ class ObjectSerializer
// push key itself
$result[] = $prop;
}

if ($v instanceof BackedEnum) {
$v = $v->value;
}

$result[$prop] = $v;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@

namespace OpenAPI\Client;

use BackedEnum;
use DateTimeInterface;
use DateTime;
use GuzzleHttp\Psr7\Utils;
Expand Down Expand Up @@ -263,6 +264,11 @@ public static function toQueryValue(
// push key itself
$result[] = $prop;
}

if ($v instanceof BackedEnum) {
$v = $v->value;
}

$result[$prop] = $v;
}
}
Expand Down
6 changes: 6 additions & 0 deletions samples/client/echo_api/php-nextgen/src/ObjectSerializer.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@

namespace OpenAPI\Client;

use BackedEnum;
use DateTimeInterface;
use DateTime;
use GuzzleHttp\Psr7\Utils;
Expand Down Expand Up @@ -263,6 +264,11 @@ public static function toQueryValue(
// push key itself
$result[] = $prop;
}

if ($v instanceof BackedEnum) {
$v = $v->value;
}

$result[$prop] = $v;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@

namespace OpenAPI\Client;

use BackedEnum;
use DateTimeInterface;
use DateTime;
use GuzzleHttp\Psr7\Utils;
Expand Down Expand Up @@ -262,6 +263,11 @@ public static function toQueryValue(
// push key itself
$result[] = $prop;
}

if ($v instanceof BackedEnum) {
$v = $v->value;
}

$result[$prop] = $v;
}
}
Expand Down
Loading