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

Paths like '//@' throws error #4

Open
AxlLind opened this issue Oct 24, 2018 · 0 comments
Open

Paths like '//@' throws error #4

AxlLind opened this issue Oct 24, 2018 · 0 comments

Comments

@AxlLind
Copy link

AxlLind commented Oct 24, 2018

I'm not sure if this package is being maintained any more but a path like //@ (i.e starts with a '/' and contains a @) will make this middleware throw an error.

var pathname = url.parse(req.url).pathname;

The line above will return null which makes the following line throw an error:

var cacheValue = cacheValues(slasher(pathname));

It's a strange edge-case I know but it's something I ran into.

@AxlLind AxlLind changed the title Paths like Paths like '//@' throws error Oct 24, 2018
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

1 participant