File tree Expand file tree Collapse file tree 1 file changed +19
-15
lines changed Expand file tree Collapse file tree 1 file changed +19
-15
lines changed Original file line number Diff line number Diff line change @@ -260,13 +260,15 @@ TABS.receiver.initialize = function (callback) {
260260 serialRxSelectElement . val ( FC . RX_CONFIG . serialrx_provider ) ;
261261
262262 // Convert to select2 and order alphabetic
263- serialRxSelectElement . select2 ( {
264- sorter ( data ) {
265- return data . sort ( function ( a , b ) {
266- return a . text . localeCompare ( b . text ) ;
267- } ) ;
268- } ,
269- } ) ;
263+ if ( ! GUI . isCordova ( ) ) {
264+ serialRxSelectElement . select2 ( {
265+ sorter ( data ) {
266+ return data . sort ( function ( a , b ) {
267+ return a . text . localeCompare ( b . text ) ;
268+ } ) ;
269+ } ,
270+ } ) ;
271+ }
270272
271273 if ( semver . gte ( FC . CONFIG . apiVersion , API_VERSION_1_31 ) ) {
272274 const spiRxTypes = [
@@ -332,14 +334,16 @@ TABS.receiver.initialize = function (callback) {
332334 // select current serial RX type
333335 spiRxElement . val ( FC . RX_CONFIG . rxSpiProtocol ) ;
334336
335- // Convert to select2 and order alphabetic
336- spiRxElement . select2 ( {
337- sorter ( data ) {
338- return data . sort ( function ( a , b ) {
339- return a . text . localeCompare ( b . text ) ;
340- } ) ;
341- } ,
342- } ) ;
337+ if ( ! GUI . isCordova ( ) ) {
338+ // Convert to select2 and order alphabetic
339+ spiRxElement . select2 ( {
340+ sorter ( data ) {
341+ return data . sort ( function ( a , b ) {
342+ return a . text . localeCompare ( b . text ) ;
343+ } ) ;
344+ } ,
345+ } ) ;
346+ }
343347 }
344348
345349
You can’t perform that action at this time.
0 commit comments