From larrytheliquid

Merge commit '4d05a2cf2b2de34dda0a3e805ab11b60540578df'
This commit is contained in:
mike.gaffney 2009-06-01 11:59:21 -05:00
commit b85aacae1c
1 changed files with 3 additions and 1 deletions

View File

@ -1,6 +1,8 @@
var links = inDocument.getElementsByTagName('a');
var candidateLinks = $A(links).select(function(candidateLink) {
return PatternMatcher.matches(locator, getText(candidateLink));
var textMatched = PatternMatcher.matches(locator, getText(candidateLink));
var idMatched = PatternMatcher.matches(locator, candidateLink.id);
return textMatched || idMatched;
});
if (candidateLinks.length == 0) {
return null;