Return the promise.

This commit is contained in:
James Cole
2025-07-30 08:37:19 +02:00
parent a2d2b7edd3
commit 8b57f45963
3 changed files with 9 additions and 5 deletions

View File

@@ -71,9 +71,10 @@ let index = function () {
return {
convertToNative: false,
saveNativeSettings(event) {
setVariable('convert_to_native', event.currentTarget.checked);
this.$dispatch('convert-to-native', event.currentTarget.checked);
console.log('saveNativeSettings + dispatch.');
setVariable('convert_to_native', event.currentTarget.checked).then(() => {
console.log('Set convert to native to: ', event.currentTarget.checked);
this.$dispatch('convert-to-native', event.currentTarget.checked);
});
},
init() {
Promise.all([getVariable('convert_to_native', false)]).then((values) => {