Skip to content
This repository has been archived by the owner on May 10, 2018. It is now read-only.

Commit

Permalink
Removed wrong error message default, fixes #31
Browse files Browse the repository at this point in the history
  • Loading branch information
uuf6429 committed May 26, 2017
1 parent 5b2b80d commit 8db4994
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
7 changes: 1 addition & 6 deletions src/ElectronDriver.php
Original file line number Diff line number Diff line change
Expand Up @@ -1031,12 +1031,7 @@ protected function handleExecutionResponse($errorMessageTpl, $allowRedirect = tr
$result = $this->waitForAsyncResult('getExecutionResponse');

if (isset($result['error'])) {
throw new DriverException(
sprintf(
$errorMessageTpl ?: 'Could not dispatch mouse event: %s',
$result['error']
)
);
throw new DriverException(sprintf($errorMessageTpl, $result['error']));
}

if ($allowRedirect && isset($result['redirect']) && $result['redirect']) {
Expand Down
4 changes: 3 additions & 1 deletion src/Server/Preload.js
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,9 @@
window.addEventListener(
rdEventTypeToJsEventMap[rdEventType],
function (event) {
setMouseEventTriggered((event && event.target) ? this.getElementSelector(event.target) : 'unknown');
setMouseEventTriggered(
(event && event.target) ? this.getElementSelector(event.target) : 'unknown'
);
},
{catpure: true, once: true}
);
Expand Down

0 comments on commit 8db4994

Please sign in to comment.