Skip to content

Commit

Permalink
fix(bug): by.buttonText() should not be effected by CSS style
Browse files Browse the repository at this point in the history
Closes issue #1904
  • Loading branch information
sjelin committed Mar 7, 2015
1 parent 29ce5c6 commit 8a3412e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/clientsidescripts.js
Expand Up @@ -482,7 +482,7 @@ functions.findByButtonText = function(searchText, using) {
var element = elements[i];
var elementText;
if (element.tagName.toLowerCase() == 'button') {
elementText = element.innerText || element.textContent;
elementText = element.textContent || element.innerText || '';
} else {
elementText = element.value;
}
Expand Down Expand Up @@ -511,7 +511,7 @@ functions.findByPartialButtonText = function(searchText, using) {
var element = elements[i];
var elementText;
if (element.tagName.toLowerCase() == 'button') {
elementText = element.innerText || element.textContent;
elementText = element.textContent || element.innerText || '';
} else {
elementText = element.value;
}
Expand Down

0 comments on commit 8a3412e

Please sign in to comment.