fix #138 (keep Ox.Theme from setting a non-existing theme)

This commit is contained in:
rolux 2013-01-02 17:45:30 +01:00
parent 38ae7b4e53
commit 67f744baaf

View file

@ -84,7 +84,7 @@ Ox.Theme = (function() {
function setTheme(theme) {
var currentTheme = getTheme();
if (theme != currentTheme) {
if (theme != currentTheme && Ox.contains(that.getThemes(), theme)) {
Ox.UI.$body
.addClass(
'OxTheme'