From b9f5536d93532b3d9d357932b10260c193160d78 Mon Sep 17 00:00:00 2001 From: Hans Christian Olaussen <41271048+klutvott123@users.noreply.github.com> Date: Mon, 17 Feb 2020 22:32:15 +0100 Subject: [PATCH] Fix lua powerTable The entries in this table should be strings. --- src/js/tabs/vtx.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/js/tabs/vtx.js b/src/js/tabs/vtx.js index 1b590811..d17db390 100644 --- a/src/js/tabs/vtx.js +++ b/src/js/tabs/vtx.js @@ -588,7 +588,7 @@ TABS.vtx.initialize = function (callback) { writer.onwriteend = function() { dump_html_to_msp(); const vtxConfig = createVtxConfigInfo(); - const text = creatLuaTables(vtxConfig); + const text = createLuaTables(vtxConfig); const data = new Blob([text], { type: "application/text" }); // we get here at the end of the truncate method, change to the new end @@ -935,7 +935,7 @@ TABS.vtx.initialize = function (callback) { return vtxConfig; } - function creatLuaTables(vtxConfig) { + function createLuaTables(vtxConfig) { let bandsString = "bandTable = { [0]=\"U\""; let frequenciesString = "frequencyTable = {\n"; @@ -957,7 +957,7 @@ TABS.vtx.initialize = function (callback) { const powerList = vtxConfig.vtx_table.powerlevels_list; let powersString = "powerTable = { "; for (let index = 0, len = powerList.length; index < len; ++index) { - powersString += `[${(index + 1)}]=${powerList[index].label}, `; + powersString += `[${(index + 1)}]="${powerList[index].label}", `; } powersString += "},\n";