User Themes: don't load a null stylesheet

If the stylesheet is not set, or it cannot be found, don't try to
load it.
This commit is contained in:
Giovanni Campagna
2011-03-19 18:21:27 +01:00
parent 1639f9f624
commit a4d7a4eba4
+5 -3
View File
@@ -31,9 +31,11 @@ ThemeManager.prototype = {
_stylesheet = _userCssStylesheet;
}
global.log('loading user theme: ' + _stylesheet)
Main.setThemeStylesheet(_stylesheet);
Main.loadTheme();
if (_stylesheet) {
global.log('loading user theme: ' + _stylesheet)
Main.setThemeStylesheet(_stylesheet);
Main.loadTheme();
}
}
}