Skip to content

Commit 807b4f5

Browse files
committed
[js] cleanup from bad rebase
1 parent e943779 commit 807b4f5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

javascript/node/selenium-webdriver/lib/webdriver.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -989,7 +989,7 @@ class WebDriver {
989989
* @private
990990
*/
991991
findElementInternal_(locatorFn, context) {
992-
return this.call(() => locatorFn(context)).then(function(result) {
992+
return Promise.resolve(locatorFn(context)).then(function(result) {
993993
if (Array.isArray(result)) {
994994
result = result[0];
995995
}
@@ -1029,7 +1029,7 @@ class WebDriver {
10291029
* @private
10301030
*/
10311031
findElementsInternal_(locatorFn, context) {
1032-
return this.call(() => locatorFn(context)).then(function(result) {
1032+
return Promise.resolve(locatorFn(context)).then(function(result) {
10331033
if (result instanceof WebElement) {
10341034
return [result];
10351035
}

0 commit comments

Comments
 (0)