From 7e61ca260e51b5656a476bfc7e4daec68cd3a2e4 Mon Sep 17 00:00:00 2001 From: phl0 Date: Fri, 31 Oct 2025 14:55:54 +0100 Subject: [PATCH] Revert "Clear refs before filling spot data" This reverts commit 813e1c7f5e9438bd3750f7393bfb07a1b5700b20. --- assets/js/dxwaterfall.js | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/assets/js/dxwaterfall.js b/assets/js/dxwaterfall.js index a35255e57..cf45b71a2 100644 --- a/assets/js/dxwaterfall.js +++ b/assets/js/dxwaterfall.js @@ -1219,9 +1219,8 @@ var DX_WATERFALL_UTILS = { } // Populate SOTA reference if available (selectize field) - var $sotaSelect = $('#sota_ref'); - $sotaSelect[0].selectize.clear(); if (spotData.sotaRef && spotData.sotaRef !== '') { + var $sotaSelect = $('#sota_ref'); if ($sotaSelect.length > 0 && $sotaSelect[0].selectize) { var sotaSelectize = $sotaSelect[0].selectize; sotaSelectize.addOption({name: spotData.sotaRef}); @@ -1230,9 +1229,8 @@ var DX_WATERFALL_UTILS = { } // Populate POTA reference if available (selectize field) - var $potaSelect = $('#pota_ref'); - $potaSelect[0].selectize.clear(); if (spotData.potaRef && spotData.potaRef !== '') { + var $potaSelect = $('#pota_ref'); if ($potaSelect.length > 0 && $potaSelect[0].selectize) { var potaSelectize = $potaSelect[0].selectize; potaSelectize.addOption({name: spotData.potaRef}); @@ -1241,9 +1239,8 @@ var DX_WATERFALL_UTILS = { } // Populate IOTA reference if available (regular select dropdown) - var $iotaSelect = $('#iota_ref'); - $iotaSelect.val(""); if (spotData.iotaRef && spotData.iotaRef !== '') { + var $iotaSelect = $('#iota_ref'); if ($iotaSelect.length > 0) { var optionExists = $iotaSelect.find('option[value="' + spotData.iotaRef + '"]').length > 0; if (optionExists) { @@ -1260,9 +1257,8 @@ var DX_WATERFALL_UTILS = { } // Populate WWFF reference if available (selectize field) - var $wwffSelect = $('#wwff_ref'); - $wwffSelect[0].selectize.clear(); if (spotData.wwffRef && spotData.wwffRef !== '') { + var $wwffSelect = $('#wwff_ref'); if ($wwffSelect.length > 0 && $wwffSelect[0].selectize) { var wwffSelectize = $wwffSelect[0].selectize; wwffSelectize.addOption({name: spotData.wwffRef});