dperini / nwsapi

Fast CSS Selectors API Engine
MIT License
105 stars 36 forks source link

can't match mixed-case tagName #41

Closed chadkirby closed 3 years ago

chadkirby commented 3 years ago

Hi, I believe 32ac887de64f1b4b11bc7cb3db392d238bb524c2 (line 826) makes it impossible to match a mixed-case tagName in an XML document. For example, if you have an element whose outerHTML is <w:rPr/>, that element's localName ends up being rPr, not rpr as 32ac887de64f1b4b11bc7cb3db392d238bb524c2 seems to imply.

dperini commented 3 years ago

Hi Chad, are you saying that https://github.com/dperini/nwsapi/commit/32ac887de64f1b4b11bc7cb3db392d238bb524c2 should be reverted ? Can you confirm that the issue was not present before that patch and that the observed behaviour was correct ?

chadkirby commented 3 years ago

Hi, the issue was not present & observed behavior was correct as of 6dac2ca8f91c5a89705ef28f88945c3e800dc062

dperini commented 3 years ago

@chadkirby the commit https://github.com/dperini/nwsapi/commit/373ea44fdf6d02c70ea81fa370bdcce44060820c should have corrected and restored previous behavior of https://github.com/dperini/nwsapi/commit/6dac2ca8f91c5a89705ef28f88945c3e800dc062