summaryrefslogtreecommitdiff
path: root/ext/bg/js/api.js
diff options
context:
space:
mode:
authorsiikamiika <siikamiika@users.noreply.github.com>2019-10-27 23:02:41 +0200
committersiikamiika <siikamiika@users.noreply.github.com>2019-10-27 23:02:41 +0200
commit9641747ba173eb6cc64b5881759d225253935e4a (patch)
tree0e40711ded4536e5756f1bc8a85fdaa3af616d57 /ext/bg/js/api.js
parent51c35c9f306e48093fc769713675dca5b02d1398 (diff)
Revert "modify correct profile apiOptionsSet"
This reverts commit 51c35c9f306e48093fc769713675dca5b02d1398.
Diffstat (limited to 'ext/bg/js/api.js')
-rw-r--r--ext/bg/js/api.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/bg/js/api.js b/ext/bg/js/api.js
index 95787d7d..6c109614 100644
--- a/ext/bg/js/api.js
+++ b/ext/bg/js/api.js
@@ -23,7 +23,7 @@ function apiOptionsGet(optionsContext) {
async function apiOptionsSet(changedOptions, optionsContext, source) {
const backend = utilBackend();
- const {profileIndex} = backend.getProfileFromContext(optionsContext);
+ const {depth} = optionsContext;
let options = await apiOptionsGetFull();
function getValuePaths(obj) {
@@ -63,7 +63,7 @@ async function apiOptionsSet(changedOptions, optionsContext, source) {
}
for (let [value, path] of getValuePaths(changedOptions)) {
- modifyOption(path, value, options.profiles[profileIndex].options);
+ modifyOption(path, value, options.profiles[depth].options);
}
await optionsSave(options);