File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -119,11 +119,7 @@ public function generateSchemas(): array
119
119
$ swaggerProps ['description ' ] = "$ description " ;
120
120
}
121
121
122
- if (isset ($ column ['default ' ]) && $ column ['default ' ]) {
123
- $ swaggerProps ['default ' ] = $ column ['default ' ];
124
- } else {
125
- $ this ->addExampleKey ($ column );
126
- }
122
+ $ this ->addExampleKey ($ column );
127
123
128
124
if (!$ column ['nullable ' ]) {
129
125
$ required [] = $ column ['name ' ];
@@ -453,4 +449,12 @@ private function convertPhpTypeToSwaggerType(string $phpType): array
453
449
'nullable ' => true ,
454
450
];
455
451
}
452
+
453
+ private function removeQuotesIfBothEnds (string $ string )
454
+ {
455
+ if (strlen ($ string ) >= 2 && $ string [0 ] === "' " && $ string [strlen ($ string ) - 1 ] === "' " ) {
456
+ return substr ($ string , 1 , -1 );
457
+ }
458
+ return $ string ;
459
+ }
456
460
}
You can’t perform that action at this time.
0 commit comments