Skip to content
This repository was archived by the owner on Jul 29, 2024. It is now read-only.
This repository was archived by the owner on Jul 29, 2024. It is now read-only.

Error by executeAsyncScript: Detected a page unload event; async script execution does not work across page loads #1651

Closed
@emyphan

Description

@emyphan

Hi folk,
i got this error when running the executeAsyncScript():
"Detected a page unload event; async script execution does not work across page loads"

my code:
create: function (contentObj) {
return browser.executeAsyncScript(function(contentObj, callback) {
var api = angular.injector(['module']).get('moduleService');
var aContentObj = new api.Page(contentObj); //return a resource object
console.log('contentObj:' + JSON.stringify(pageContentObj));
aContentObj.$save(pageContentObj, function(createdPage) {
callback(createdPage);
});
}, contentObj);
}

Has any one the same issue by executing asynscript? Any help is very appreciated
Regards,
Emy

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions