Skip to content

Commit

Permalink
fix: calls this.settings in settings handling (#901)
Browse files Browse the repository at this point in the history
  • Loading branch information
KazuCocoa authored Aug 17, 2023
1 parent ee2d693 commit 7858760
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions lib/commands/general.js
Original file line number Diff line number Diff line change
Expand Up @@ -322,11 +322,14 @@ commands.mobileClickAction = async function mobileClickAction (opts = {}) {
};

commands.updateSettings = async function updateSettings (settings) {
return await this.espresso.jwproxy.command(`/appium/settings`, 'POST', { settings });
await this.settings.update(settings);
await this.espresso.jwproxy.command(`/appium/settings`, 'POST', { settings });
};

commands.getSettings = async function getSettings () {
return await this.espresso.jwproxy.command(`/appium/settings`, 'GET');
const driverSettings = this.settings.getSettings();
const serverSettings = await this.espresso.jwproxy.command(`/appium/settings`, 'GET');
return {...driverSettings, ...serverSettings};
};

// Stop proxying to any Chromedriver and redirect to Espresso
Expand Down

0 comments on commit 7858760

Please sign in to comment.