File tree 1 file changed +10
-9
lines changed
play.pokemonshowdown.com/js
1 file changed +10
-9
lines changed Original file line number Diff line number Diff line change 1031
1031
this . curFormat = defaultFormat ;
1032
1032
}
1033
1033
else {
1034
- this . curFormat = formatid ;
1035
- if ( ! this . curFormat ) {
1036
- if ( BattleFormats [ 'gen9randombattle' ] ) {
1037
- this . curFormat = 'gen9randombattle' ;
1038
- } else for ( var i in BattleFormats ) {
1039
- if ( ! BattleFormats [ i ] . searchShow || ! BattleFormats [ i ] . challengeShow ) continue ;
1040
- this . curFormat = i ;
1041
- break ;
1034
+ this . curFormat = formatid ;
1035
+ if ( ! this . curFormat ) {
1036
+ if ( BattleFormats [ 'gen9randombattle' ] ) {
1037
+ this . curFormat = 'gen9randombattle' ;
1038
+ } else for ( var i in BattleFormats ) {
1039
+ if ( ! BattleFormats [ i ] . searchShow || ! BattleFormats [ i ] . challengeShow ) continue ;
1040
+ this . curFormat = i ;
1041
+ break ;
1042
+ }
1042
1043
}
1043
1044
}
1044
- }
1045
1045
formatid = this . curFormat ;
1046
1046
}
1047
1047
return '<button class="select formatselect' + ( noChoice ? ' preselected' : '' ) + '" name="format" value="' + formatid + '"' + ( noChoice ? ' disabled' : '' ) + '>' + BattleLog . escapeFormat ( formatid ) + '</button>' ;
1438
1438
} ) ;
1439
1439
}
1440
1440
this . sourceEl . val ( format ) . html ( BattleLog . escapeFormat ( format ) || '(Select a format)' ) ;
1441
+ Storage . prefs ( 'defaultformat' , format ) ;
1441
1442
1442
1443
this . close ( ) ;
1443
1444
}
You can’t perform that action at this time.
0 commit comments