You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Event.findElement causes error if nothing matches the given pattern #4
If you call Event.findElement with a pattern that doesn't match any elements in the ancestor chain, you get an error (in Chrome and FF) caused by getAttribute() being called on the root HTML document object, which doesn't have a getAttribute method. It is easily reproducible:
Oh, didn't know about '*[blah]'. I guess I figured if the syntax was invalid, the selector would have failed earlier. :) Thanks for moving it to lighthouse, wasn't sure where the right place to report this was.
Activity
dandean commentedon Mar 1, 2010
Hi Jamis,
Wouldn't the correct selector be
event.findElement('*[bogus-attr]').In any event, I'm going to move this report over to the lighthouse. Thanks!
dandean commentedon Mar 1, 2010
Jamis, you can track progress on this issue here:
https://prototype.lighthouseapp.com/projects/8886-prototype/tickets/999
Please post any future issues over on the lighthouse project.
jamis commentedon Mar 1, 2010
Oh, didn't know about '*[blah]'. I guess I figured if the syntax was invalid, the selector would have failed earlier. :) Thanks for moving it to lighthouse, wasn't sure where the right place to report this was.
tobie commentedon Mar 1, 2010
That's a Sizzle bug, I'm afraid.