mirror of
https://github.com/appium/appium.git
synced 2026-02-21 18:59:08 -06:00
preventing pageLoad cbs being called twice
This commit is contained in:
@@ -371,7 +371,7 @@ RemoteDebugger.prototype.pageUnload = function (cb) {
|
||||
RemoteDebugger.prototype.waitForDom = function (cb) {
|
||||
this.logger.debug("Waiting for dom...");
|
||||
if (typeof cb === "function") {
|
||||
this.pageLoadedCbs.push(cb);
|
||||
this.pageLoadedCbs.push(_.once(cb));
|
||||
}
|
||||
this.pageLoad();
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user