Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TASK: Remove CORS header and adjust readme #26

Merged
merged 1 commit into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion Classes/Controller/OpenApiDocumentController.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ public function renderAction(string $name): string
{
$schema = $this->documentRepository->findDocumentByName($name);
$this->response->setContentType('application\json');
$this->response->addHttpHeader('Access-Control-Allow-Origin', '*');
return \json_encode(
$schema,
JSON_THROW_ON_ERROR | JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE
Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,8 @@ _!!! There is a small chance the arguments passed to the constructor are not sto

## Installation

Sitegeist.SchemeOnYou is available via packagist. Run `composer require sitegeist/schemeonyou` to require this package.
Sitegeist.SchemeOnYou is available via packagist. Run `composer require sitegeist/schemeonyou` to require this package.
You may also want to install `flowpack/cors` or any other CORS package if you are using the endpoints from different urls .

We use semantic versioning, so every breaking change will increase the major version number.

Expand Down
3 changes: 3 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
"mikey179/vfsstream": "^1.6",
"squizlabs/php_codesniffer": "^3.7"
},
"suggests": {
"flowpack/cors": "*"
},
"autoload": {
"psr-4": {
"Sitegeist\\SchemeOnYou\\": "Classes/"
Expand Down
Loading