diff options
author | Pawel Spychalski (DzikuVx) <pspychalski@gmail.com> | 2018-05-02 22:17:32 +0300 |
---|---|---|
committer | Pawel Spychalski (DzikuVx) <pspychalski@gmail.com> | 2018-05-02 22:17:32 +0300 |
commit | 35170f74dd8def7e3cf2f622261680f6ef82bad2 (patch) | |
tree | 4d9fc152cd8182ff85afc6c0216152af347a5ff1 /tabs | |
parent | 9961fc1476800f796181bd81101b4845266501f4 (diff) |
fixed RX protocol tracking vol. 2
Diffstat (limited to 'tabs')
-rw-r--r-- | tabs/configuration.js | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/tabs/configuration.js b/tabs/configuration.js index abddbe49..5fcd3ccd 100644 --- a/tabs/configuration.js +++ b/tabs/configuration.js @@ -699,22 +699,13 @@ TABS.configuration.initialize = function (callback, scrollPosition) { var rxTypes = FC.getRxTypes(); - function is_using_rx_type(name) { - for (var ii = 0; ii < rxTypes.length; ii++) { - if (rxTypes[ii].name == name) { - return FC.isRxTypeEnabled(rxTypes[ii]); - } - } - return false; - } - // track feature usage - if (is_using_rx_type('RX_SERIAL')) { - googleAnalytics.sendEvent('Setting', 'SerialRxProvider', serialRxTypes[RX_CONFIG.serialrx_provider]); + if ($('#rxType').val() == 'RX_SERIAL') { + googleAnalytics.sendEvent('Setting', 'SerialRxProvider', $('#serial-rx-protocol').find(':selected').text()); } // track feature usage - if (is_using_rx_type('RX_SPI')) { + if ($('#rxType').val() == 'RX_SPI') { googleAnalytics.sendEvent('Setting', 'nrf24Protocol', FC.getSPIProtocolTypes()[RX_CONFIG.spirx_protocol]); } |