call Ox.localStorage only once
This commit is contained in:
parent
175c8b23d0
commit
23ad209561
1 changed files with 5 additions and 4 deletions
|
@ -9,7 +9,8 @@ Ox.Theme <f> get/set theme
|
||||||
|
|
||||||
Ox.Theme = (function() {
|
Ox.Theme = (function() {
|
||||||
|
|
||||||
var that = function(theme) {
|
var localStorage = Ox.localStorage('Ox'),
|
||||||
|
that = function(theme) {
|
||||||
return theme ? setTheme(theme) : getTheme();
|
return theme ? setTheme(theme) : getTheme();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -123,7 +124,7 @@ Ox.Theme = (function() {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
Ox.localStorage('Ox')('theme', theme);
|
localStorage({theme: theme});
|
||||||
return that;
|
return that;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue