Skip to content

Paths like '//@' throws error #4

Description

@AxlLind

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.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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