[themes] refactoring. skip es6 syntax
This commit is contained in:
parent
6bc4ef744f
commit
b2777666b8
|
@ -249,12 +249,11 @@ define([
|
|||
var theme_name = get_ui_theme_name(Common.localStorage.getItem('ui-theme'));
|
||||
if ( !theme_name ) {
|
||||
if ( !(Common.Utils.isIE10 || Common.Utils.isIE11) )
|
||||
for (var i of document.body.classList.entries()) {
|
||||
if ( i[1].startsWith('theme-') && !i[1].startsWith('theme-type-') ) {
|
||||
theme_name = i[1];
|
||||
break;
|
||||
document.body.classList.forEach(function (classname, i, o) {
|
||||
if ( !theme_name && classname.startsWith('theme-') && !classname.startsWith('theme-type-') ) {
|
||||
theme_name = classname;
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
if ( !themes_map[theme_name] )
|
||||
|
|
Loading…
Reference in a new issue