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
119119 $ swaggerProps ['description ' ] = "$ description " ;
120120 }
121121
122- if (isset ($ column ['default ' ]) && $ column ['default ' ]) {
123- $ swaggerProps ['default ' ] = $ column ['default ' ];
124- } else {
125- $ this ->addExampleKey ($ column );
126- }
122+ $ this ->addExampleKey ($ column );
127123
128124 if (!$ column ['nullable ' ]) {
129125 $ required [] = $ column ['name ' ];
@@ -453,4 +449,12 @@ private function convertPhpTypeToSwaggerType(string $phpType): array
453449 'nullable ' => true ,
454450 ];
455451 }
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+ }
456460}
You can’t perform that action at this time.
0 commit comments