Skip to content

Commit

Permalink
fix(merge-specs): Remove accidental value casting
Browse files Browse the repository at this point in the history
Signed-off-by: provokateurin <[email protected]>
  • Loading branch information
provokateurin committed Jan 11, 2024
1 parent 3c90fce commit ae01f36
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion merge-specs
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ function loadSpec(string $path): array {

function rewriteRefs(array $spec): array {
$readableAppID = Helpers::generateReadableAppID($spec["info"]["title"]);
array_walk_recursive($spec, function (string &$item, string $key) use ($readableAppID) {
array_walk_recursive($spec, function (mixed &$item, string $key) use ($readableAppID) {
if ($key == "\$ref" && $item != "#/components/schemas/OCSMeta") {
$item = str_replace("#/components/schemas/", "#/components/schemas/" . $readableAppID, $item);
}
Expand Down

0 comments on commit ae01f36

Please sign in to comment.