Skip to content

Commit

Permalink
🐛 Fix Conduit#parseRequest() forgetting GET query parameters when o…
Browse files Browse the repository at this point in the history
…verriding respone url
  • Loading branch information
skerit committed Dec 27, 2024
1 parent d9c21bb commit c672882
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 1.4.0-alpha.9 (WIP)

* Fix `Conduit#parseRequest()` forgetting GET query parameters when overriding respone url

## 1.4.0-alpha.8 (2024-11-28)

* Fix `_modelInstance` cache when keys are not strings
Expand Down
4 changes: 2 additions & 2 deletions lib/class/conduit.js
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,7 @@ Conduit.setMethod(function time() {
*
* @author Jelle De Loecker <jelle@elevenways.be>
* @since 0.2.0
* @version 1.3.18
* @version 1.4.0
*
* @param {IncomingMessage} req
* @param {ServerResponse} res
Expand Down Expand Up @@ -541,7 +541,7 @@ Conduit.setMethod(async function parseRequest() {
}

if (this.rewritten_request_route_param) {
let params = Object.assign({}, this.route_string_parameters, this.rewritten_request_route_param);
let params = Object.assign({...this.url.query}, this.route_string_parameters, this.rewritten_request_route_param);
let new_url = this.route.generateUrl(params, this);
this.overrideResponseUrl(new_url);
}
Expand Down

0 comments on commit c672882

Please sign in to comment.