Skip to content

Calculation of indexOfQuery incorrectΒ #50

@andrejpavlovic

Description

@andrejpavlovic

require: givenRelativePath => {
const indexOfQuery = Math.max(givenRelativePath.indexOf("?"), givenRelativePath.length);
const relativePathWithoutQuery = givenRelativePath.slice(0, indexOfQuery);

Shouldn't this be Math.min not Math.max? Otherwise we might as well write:

const indexOfQuery = givenRelativePath.length;

I've rolled back to 2.0.1 in order to use oneOf/resourceQuery in webpack config until this is fixed.

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