mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-26 20:34:02 +03:00
0e9d4e6792
Refs #4001 - grunt-jscs@0.8.1 which provides ES6 support.
23 lines
636 B
JavaScript
23 lines
636 B
JavaScript
import CurrentUserSettings from 'ghost/mixins/current-user-settings';
|
|
import styleBody from 'ghost/mixins/style-body';
|
|
|
|
var AppsRoute = Ember.Route.extend(SimpleAuth.AuthenticatedRouteMixin, styleBody, CurrentUserSettings, {
|
|
classNames: ['settings-view-apps'],
|
|
|
|
beforeModel: function () {
|
|
if (!this.get('config.apps')) {
|
|
return this.transitionTo('settings.general');
|
|
}
|
|
|
|
return this.currentUser()
|
|
.then(this.transitionAuthor())
|
|
.then(this.transitionEditor());
|
|
},
|
|
|
|
model: function () {
|
|
return this.store.find('app');
|
|
}
|
|
});
|
|
|
|
export default AppsRoute;
|