forked from loafle/openapi-generator-original
* [PHP/Dart/Python] Correctly escape strings in single quotes (Fixes #17582) * Move escapeTextInSingleQuotes method to DefaultCodegen, add docblock
This commit is contained in:
@@ -44,9 +44,9 @@ use JMS\Serializer\Annotation\SerializedName;
|
||||
*/
|
||||
enum EnumStringModel: string
|
||||
{
|
||||
case AVAILABLE = "available";
|
||||
case PENDING = "pending";
|
||||
case SOLD = "sold";
|
||||
case AVAILABLE = 'available';
|
||||
case PENDING = 'pending';
|
||||
case SOLD = 'sold';
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -84,7 +84,7 @@ class Order
|
||||
* @SerializedName("status")
|
||||
* @Type("string")
|
||||
*/
|
||||
#[Assert\Choice(["placed", "approved", "delivered"])]
|
||||
#[Assert\Choice(['placed', 'approved', 'delivered'])]
|
||||
#[Assert\Type("string")]
|
||||
protected ?string $status = null;
|
||||
|
||||
|
||||
@@ -98,7 +98,7 @@ class Pet
|
||||
* @SerializedName("status")
|
||||
* @Type("string")
|
||||
*/
|
||||
#[Assert\Choice(["available", "pending", "sold"])]
|
||||
#[Assert\Choice(['available', 'pending', 'sold'])]
|
||||
#[Assert\Type("string")]
|
||||
protected ?string $status = null;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user