question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

_parsedUrl.url is undefined - version 1.0.0-next.3

See original GitHub issue

Hi thanks for the great library!

This line is throwing TypeError: Cannot read property 'substring' of undefined when running custom middleware.

https://github.com/lukeed/polka/blob/602086f1f4f1a6103e0589b04b69f8b4d934f0fc/packages/polka/index.mjs#L30

I believe its caused by this line

https://github.com/lukeed/polka/blob/602086f1f4f1a6103e0589b04b69f8b4d934f0fc/packages/polka/index.mjs#L36

As far as I can tell, the latest version of @polka/url doesn’t set the url on the _parsedUrl. Is this a bug? Or am I missing something?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
lukeedcommented, May 23, 2019

Now included in polka@1.0.0-next.4 – much appreciated

0reactions
lukeedcommented, May 23, 2019

You were right, thank you! 🙌

Read more comments on GitHub >

github_iconTop Results From Across the Web

URL is not defined in node.js - Stack Overflow
Try to add this line: var URL = require('url').URL;. The full example is here: var URL = require('url').URL; var myURL = new ...
Read more >
SvelteKit loads favicon every page request and messes up the ...
I'm on SvelteKit v1.0.0-next.295 with adapter-static@1.0.0-next.29 and with or without trailingSlash: 'always' the favicon problem is still ...
Read more >
URL | Node.js v19.3.0 Documentation
A URL string is a structured string containing multiple meaningful components. When parsed, a URL object is returned containing properties for each of...
Read more >
url-parse - npm
Small footprint URL parser that works seamlessly across Node.js and browser environments. Latest version: 1.5.10, last published: 10 months ...
Read more >
Node.js URL Module - W3Schools
The URL module splits up a web address into readable parts. ... Parse an address with the url.parse() method, and it will return...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found