Skip to content

Commit

Permalink
Merge pull request #714 from zgosalvez/fix-laravel-postman
Browse files Browse the repository at this point in the history
Fixes Laravel route to postman collection
  • Loading branch information
shalvah authored Mar 26, 2020
2 parents ac9beb4 + 81603e9 commit 5cab045
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Writing/Writer.php
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ protected function moveOutputFromSourceFolderToTargetFolder(): void
$contents = str_replace('href="css/style.css"', 'href="/docs/css/style.css"', $contents);
$contents = str_replace('src="js/all.js"', 'src="/docs/js/all.js"', $contents);
$contents = str_replace('src="images/', 'src="/docs/images/', $contents);
$contents = preg_replace('#href="https?://.+?/docs/collection.json"#', 'href="{{ route("apidoc", ["format" => ".json"]) }}"', $contents);
$contents = preg_replace('#href="https?://.+?/docs/collection.json"#', 'href="{{ route("apidoc.json") }}"', $contents);
file_put_contents("$this->outputPath/index.blade.php", $contents);
}
}
Expand Down

0 comments on commit 5cab045

Please sign in to comment.