matthewmueller / x-ray

The next web scraper. See through the <html> noise.
MIT License
5.87k stars 349 forks source link

isUrl module breaks nesting #308

Closed evilive3000 closed 5 years ago

evilive3000 commented 6 years ago

because of this issue nested selections does not work.

davisjam commented 6 years ago

I just opened a PR on that issue.

davisjam commented 6 years ago

New version should be available today or tomorrow, monitor this PR.

Raidus commented 6 years ago

Having a similar problem. is-url version 1.2.3 causes some problems with html as input:

x(html, '.s-result-item.celwidget', ...

Error:

TypeError: string.match is not a function
    at isUrl (...node_modules/is-url/index.js:27:22)

With is-url version 1.2.2 there are no problems.

davisjam commented 6 years ago

Please try with is-url version 1.2.4, just published to npm. If you have any issues, open one against the is-url project.

Raidus commented 6 years ago

thanks @davisjam! updating to version 1.2.4 resolved the issue.