Skip to content

Commit

Permalink
Merge pull request #73 from swagindustries/fix/wrong-error-message
Browse files Browse the repository at this point in the history
  • Loading branch information
Nek- authored Sep 3, 2023
2 parents 370a666 + e51be63 commit 8bafe10
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,10 +129,10 @@ melodiia:

```yaml
# The documentation should be available only in dev environment in some cases
# /config/routing_dev.yaml
documentation:
path: /documentation
controller: 'melodiia.documentation'
when@dev:
documentation:
path: /api/v1/documentation
controller: 'melodiia.documentation'
```

⚠️ The render of the documentation cannot work without Twig. Be sure Twig is installed.
Expand Down
2 changes: 1 addition & 1 deletion src/Documentation/Controller/SwaggerUiController.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public function __invoke(Request $request)
}

if (null === $path) {
throw new MelodiiaLogicException(sprintf('The option %s is missing on the documentation route', self::PATH_TO_OPEN_API_FILE_OPTION));
throw new MelodiiaLogicException(sprintf('Either you forgot to specify the option %s on your API endpoint configuration or this route is not under the path of you configuration', MelodiiaConfiguration::CONFIGURATION_OPENAPI_PATH));
}

if (!file_exists($path)) {
Expand Down

0 comments on commit 8bafe10

Please sign in to comment.