Skip to content

Wrong queryString when building navigation plan in aurelia-router #639

Description

@MartyBoi

I'm submitting a bug report

  • Library Version:
    1.7.1

Please tell us about your environment:

  • Operating System:
    Windows 10

  • Node Version:
    10.15.1

  • NPM Version:
    6.4.1

  • JSPM OR Webpack AND Version
    webpack 4.29.6

  • Browser:
    all

  • Language:
    TypeScript

Current behavior:
Not redirected with correct query parameter. We are using aurelia-open-id-connect and when redirected back from our identity provider the query parameters are removed when creating the redirectPlan in aurelia-router, navigation-plan.ts.
In my example you can see that the path we're navigating to is "/example?test=123". But in the end the query string is removed because the wrong instruction is used when getting query params.

image

  • What is the expected behavior?
    Instead of getting queryString from instruction like this:
if (instruction.queryString) {
    redirectLocation += '?' + instruction.queryString;
}

I think you should get it from redirectInstruction like this:

if (redirectInstruction.queryString) {
    redirectLocation += '?' + newInstruction.queryString;
}

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions