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

PiwikTracker.track sends URLs with appended slash #51

Open
ingmarh opened this issue Feb 9, 2018 · 1 comment
Open

PiwikTracker.track sends URLs with appended slash #51

ingmarh opened this issue Feb 9, 2018 · 1 comment

Comments

@ingmarh
Copy link

ingmarh commented Feb 9, 2018

url-join had a bug, leading to an additional "/" that was appended to the URL send with PiwikTracker.track.

# with url-join 1.1.0
$ node -pe "require('url-join')('/path', '')"
/path/
$ node -pe "require('url-join')('/', '')"
//

# with url-join 4.0.0
$ node -pe "require('url-join')('/path', '')"
/path
$ node -pe "require('url-join')('/', '')"

Piwik React Router has url-join currently locked at version ^1.1.0, so an update should fix this.

Is there a specific reason why urljoin(loc.pathname, loc.search) is used instead of loc.pathname + loc.search?

walokra pushed a commit to walokra/piwik-react-router that referenced this issue Oct 11, 2018
walokra pushed a commit to walokra/piwik-react-router that referenced this issue Oct 11, 2018
walokra pushed a commit to walokra/piwik-react-router that referenced this issue Oct 11, 2018
@bitconym
Copy link

I noticed the same, updating url-join dependency will solve this. Hoping the fix will be merged into the main branch.

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

No branches or pull requests

2 participants