Skip to content

Commit

Permalink
fix warnings thrown
Browse files Browse the repository at this point in the history
  • Loading branch information
hannojg committed Oct 27, 2023
1 parent 8152008 commit 9ea214d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/libs/E2E/client.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@ const sendNativeCommand = (payload) =>
},
body: JSON.stringify(payload),
}).then((res) => {
if (res.statusCode === 200) {
if (res.status === 200) {
return true;
}
const errorMsg = `Sending native command failed with status code ${res.statusCode}`;
const errorMsg = `Sending native command failed with status code ${res.status}`;
res.json()
.then((responseText) => {
throw new Error(`${errorMsg}: ${responseText}`);
Expand Down
3 changes: 2 additions & 1 deletion tests/e2e/server/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,8 @@ const createServerInstance = () => {
.then((data) =>
executeFromPayload(data.actionName, data.payload).then((status) => {
if (status) {
return res.end('ok');
res.end('ok');
return;
}
res.statusCode = 500;
res.end('Error executing command');
Expand Down

0 comments on commit 9ea214d

Please sign in to comment.