Skip to content

Not recognizing query params when using: ...)?... #144

@fladenstein

Description

@fladenstein

Anchorme Version: 3.0.8

Description

When using anchorme.list() with the following link:

www.example.com/(test)?test=test

it will only return the following:

[
  {
    start: 0,
    end: 30,
    string: 'https://www.example.com/(test)',
    isURL: true,
    protocol: 'https://',
    port: undefined,
    ipv4: undefined,
    ipv6: undefined,
    host: 'www.example.com',
    confirmedByProtocol: true,
    path: '/(test)',
    query: undefined,
    fragment: undefined,
    reason: 'url'
  }
]

However, it should actually be:

[
  {
    start: 0,
    end: 30,
    string: 'https://www.example.com/(test)?test=test',
    isURL: true,
    protocol: 'https://',
    port: undefined,
    ipv4: undefined,
    ipv6: undefined,
    host: 'www.example.com',
    confirmedByProtocol: true,
    path: '/(test)',
    query: 'test=test',
    fragment: undefined,
    reason: 'url'
  }
]

The issue seems to be the )?, because it works with the following link: https://www.example.com/(test)/?test=test

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions