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: #331 mergeParams always true for internal services #332

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

ggondim
Copy link

@ggondim ggondim commented Aug 28, 2023

I discovered that mergeParams: false was the cause of the issue #331.

Developers should continue to use this configuration without experiencing side effects in internal services.

I implemented a minor workaround in src/index.js:L455 to force parameter merging for internal services, and it resolved the issue.

image

src/index.js Outdated Show resolved Hide resolved
Co-authored-by: Nico <freezystem@gmail.com>
Copy link
Member

@icebob icebob left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add relevant test cases as well.

@@ -452,6 +452,11 @@ module.exports = {
urlPath = urlPath.replace(this._isscRe, "$");
let action = urlPath;

// #331 Always merge parameters for internal services
if (action.startsWith("$")) {
route.opts.mergeParams = true;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This changes is too late here because the merging is happening in line 442.

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

Successfully merging this pull request may close these issues.

3 participants