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

fix(rest-explorer): exclude basePath from /openapi URL #2854

Closed
wants to merge 1 commit into from

Conversation

bajtos
Copy link
Member

@bajtos bajtos commented May 9, 2019

Endpoints serving OpenAPI spec ignore basePath setting, i.e. even if basePath is set to /api, the spec is served at /openapi.json.

This pull request is fixing the problem and supersedes #2554.

/cc @gordancso @dkrantsberg

Checklist

👉 Read and sign the CLA (Contributor License Agreement) 👈

  • npm test passes on your machine
  • New tests added or existing tests modified to cover all changes
  • Code conforms with the style guide
  • API Documentation in code was updated
  • Documentation in /docs/site was updated
  • Affected artifact templates in packages/cli were updated
  • Affected example projects in examples/* were updated

👉 Check out how to submit a PR 👈

@bajtos bajtos added this to the May 2019 milestone milestone May 9, 2019
@bajtos bajtos requested a review from raymondfeng as a code owner May 9, 2019 10:30
@bajtos bajtos self-assigned this May 9, 2019
@bajtos bajtos requested a review from a user May 9, 2019 10:37
Endpoints serving OpenAPI spec ignore basePath setting, i.e. even if
basePath is set to `/api`, the spec is served at `/openapi.json`.

Signed-off-by: Miroslav Bajtoš <mbajtoss@gmail.com>
@bajtos bajtos force-pushed the fix/base-path-in-explorer branch from 3578b81 to 1263b5e Compare May 9, 2019 10:39
@bajtos bajtos requested review from hacksparrow and nabdelgadir May 9, 2019 11:12
@bajtos
Copy link
Member Author

bajtos commented May 9, 2019

On the second thought, this is not a correct fix. While it solves the problem when basePath is set, it breaks the scenario when the entire LB4 app is mounted in another Express app. I need to rework the patch.

EDITED: opened a new PR - see #2856

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant