mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Remove trailing commas, add trailing semicolons
This commit is contained in:
parent
593f5df503
commit
3f35d1062e
@ -1,5 +1,5 @@
|
|||||||
Discourse.AdminBackupsController = Ember.ObjectController.extend({
|
Discourse.AdminBackupsController = Ember.ObjectController.extend({
|
||||||
noOperationIsRunning: Em.computed.not("isOperationRunning"),
|
noOperationIsRunning: Em.computed.not("isOperationRunning"),
|
||||||
rollbackEnabled: Em.computed.and("canRollback", "restoreEnabled", "noOperationIsRunning"),
|
rollbackEnabled: Em.computed.and("canRollback", "restoreEnabled", "noOperationIsRunning"),
|
||||||
rollbackDisabled: Em.computed.not("rollbackEnabled"),
|
rollbackDisabled: Em.computed.not("rollbackEnabled")
|
||||||
});
|
});
|
||||||
|
@ -71,6 +71,5 @@ Discourse.AdminBackupsIndexController = Ember.ArrayController.extend({
|
|||||||
}).then(function() {
|
}).then(function() {
|
||||||
Discourse.set("isReadOnly", enable);
|
Discourse.set("isReadOnly", enable);
|
||||||
});
|
});
|
||||||
},
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
Discourse.AdminBackupsLogsController = Ember.ArrayController.extend({
|
Discourse.AdminBackupsLogsController = Ember.ArrayController.extend({
|
||||||
needs: ["adminBackups"],
|
needs: ["adminBackups"],
|
||||||
status: Em.computed.alias("controllers.adminBackups"),
|
status: Em.computed.alias("controllers.adminBackups")
|
||||||
});
|
});
|
||||||
|
@ -13,8 +13,7 @@ Discourse.AdminEmailSentController = Discourse.Controller.extend({
|
|||||||
Discourse.EmailLog.findAll(this.get("filter")).then(function(logs) {
|
Discourse.EmailLog.findAll(this.get("filter")).then(function(logs) {
|
||||||
self.set("model", logs);
|
self.set("model", logs);
|
||||||
});
|
});
|
||||||
}, 250).observes("filter.user", "filter.address", "filter.type", "filter.reply_key"),
|
}, 250).observes("filter.user", "filter.address", "filter.type", "filter.reply_key")
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -32,8 +31,7 @@ Discourse.AdminEmailSkippedController = Discourse.Controller.extend({
|
|||||||
Discourse.EmailLog.findAll(this.get("filter")).then(function(logs) {
|
Discourse.EmailLog.findAll(this.get("filter")).then(function(logs) {
|
||||||
self.set("model", logs);
|
self.set("model", logs);
|
||||||
});
|
});
|
||||||
}, 250).observes("filter.user", "filter.address", "filter.type", "filter.skipped_reason"),
|
}, 250).observes("filter.user", "filter.address", "filter.type", "filter.skipped_reason")
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
|
@ -85,6 +85,5 @@ Discourse.Backup.reopenClass({
|
|||||||
window.location.pathname = Discourse.getURL("/");
|
window.location.pathname = Discourse.getURL("/");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
@ -12,6 +12,5 @@ Discourse.BackupStatus = Discourse.Model.extend({
|
|||||||
|
|
||||||
restoreEnabled: function() {
|
restoreEnabled: function() {
|
||||||
return Discourse.SiteSettings.allow_restore && !this.get("isOperationRunning");
|
return Discourse.SiteSettings.allow_restore && !this.get("isOperationRunning");
|
||||||
}.property("isOperationRunning"),
|
}.property("isOperationRunning")
|
||||||
|
|
||||||
});
|
});
|
||||||
|
@ -31,7 +31,7 @@ Discourse.AdminBackupsRoute = Discourse.Route.extend({
|
|||||||
}).then(function (status) {
|
}).then(function (status) {
|
||||||
return Discourse.BackupStatus.create({
|
return Discourse.BackupStatus.create({
|
||||||
isOperationRunning: status.is_operation_running,
|
isOperationRunning: status.is_operation_running,
|
||||||
canRollback: status.can_rollback,
|
canRollback: status.can_rollback
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -160,7 +160,6 @@ Discourse.AdminBackupsRoute = Discourse.Route.extend({
|
|||||||
|
|
||||||
uploadError: function(filename, message) {
|
uploadError: function(filename, message) {
|
||||||
bootbox.alert(I18n.t("admin.backups.upload.error", { filename: filename, message: message }));
|
bootbox.alert(I18n.t("admin.backups.upload.error", { filename: filename, message: message }));
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
@ -22,7 +22,7 @@ Discourse.AdminCustomizeView = Discourse.View.extend({
|
|||||||
selectStylesheet: function() { this.set('selected', 'stylesheet'); },
|
selectStylesheet: function() { this.set('selected', 'stylesheet'); },
|
||||||
|
|
||||||
selectMobileHeader: function() { this.set('selected', 'mobileHeader'); },
|
selectMobileHeader: function() { this.set('selected', 'mobileHeader'); },
|
||||||
selectMobileStylesheet: function() { this.set('selected', 'mobileStylesheet'); },
|
selectMobileStylesheet: function() { this.set('selected', 'mobileStylesheet'); }
|
||||||
},
|
},
|
||||||
|
|
||||||
didInsertElement: function() {
|
didInsertElement: function() {
|
||||||
|
@ -20,5 +20,5 @@ Discourse.DiscoveryController = Discourse.ObjectController.extend({
|
|||||||
showMoreDailyUrl: function() { return this.showMoreUrl('daily'); }.property('category', 'noSubcategories'),
|
showMoreDailyUrl: function() { return this.showMoreUrl('daily'); }.property('category', 'noSubcategories'),
|
||||||
showMoreWeeklyUrl: function() { return this.showMoreUrl('weekly'); }.property('category', 'noSubcategories'),
|
showMoreWeeklyUrl: function() { return this.showMoreUrl('weekly'); }.property('category', 'noSubcategories'),
|
||||||
showMoreMonthlyUrl: function() { return this.showMoreUrl('monthly'); }.property('category', 'noSubcategories'),
|
showMoreMonthlyUrl: function() { return this.showMoreUrl('monthly'); }.property('category', 'noSubcategories'),
|
||||||
showMoreYearlyUrl: function() { return this.showMoreUrl('yearly'); }.property('category', 'noSubcategories'),
|
showMoreYearlyUrl: function() { return this.showMoreUrl('yearly'); }.property('category', 'noSubcategories')
|
||||||
});
|
});
|
||||||
|
@ -12,6 +12,6 @@ Discourse.GroupController = Discourse.ObjectController.extend({
|
|||||||
// It would be nice if bootstrap marked action lists as selected when their links
|
// It would be nice if bootstrap marked action lists as selected when their links
|
||||||
// were 'active' not the `li` tags.
|
// were 'active' not the `li` tags.
|
||||||
showingIndex: Em.computed.equal('showing', 'index'),
|
showingIndex: Em.computed.equal('showing', 'index'),
|
||||||
showingMembers: Em.computed.equal('showing', 'members'),
|
showingMembers: Em.computed.equal('showing', 'members')
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -110,6 +110,6 @@ Discourse.computed = {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
return computed.property.apply(computed, args);
|
return computed.property.apply(computed, args);
|
||||||
},
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
|
@ -12,7 +12,6 @@ Discourse.ScrollTop = Em.Mixin.create({
|
|||||||
Em.run.schedule('afterRender', function() {
|
Em.run.schedule('afterRender', function() {
|
||||||
$(document).scrollTop(0);
|
$(document).scrollTop(0);
|
||||||
});
|
});
|
||||||
}.on('didInsertElement'),
|
}.on('didInsertElement')
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -66,7 +66,7 @@ Discourse.CategoryList.reopenClass({
|
|||||||
can_create_category: result.category_list.can_create_category,
|
can_create_category: result.category_list.can_create_category,
|
||||||
can_create_topic: result.category_list.can_create_topic,
|
can_create_topic: result.category_list.can_create_topic,
|
||||||
draft_key: result.category_list.draft_key,
|
draft_key: result.category_list.draft_key,
|
||||||
draft_sequence: result.category_list.draft_sequence,
|
draft_sequence: result.category_list.draft_sequence
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -19,7 +19,7 @@ Discourse.TopList.reopenClass({
|
|||||||
can_create_topic: result.can_create_topic,
|
can_create_topic: result.can_create_topic,
|
||||||
draft: result.draft,
|
draft: result.draft,
|
||||||
draft_key: result.draft_key,
|
draft_key: result.draft_key,
|
||||||
draft_sequence: result.draft_sequence,
|
draft_sequence: result.draft_sequence
|
||||||
});
|
});
|
||||||
|
|
||||||
Discourse.Site.currentProp('periods').forEach(function(period) {
|
Discourse.Site.currentProp('periods').forEach(function(period) {
|
||||||
|
@ -45,5 +45,5 @@ Discourse.DiscoveryCategoriesRoute = Discourse.Route.extend({
|
|||||||
}));
|
}));
|
||||||
this.controllerFor('editCategory').set('selectedTab', 'general');
|
this.controllerFor('editCategory').set('selectedTab', 'general');
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
});
|
});
|
||||||
|
@ -57,7 +57,7 @@ Discourse.PreferencesRoute = Discourse.RestrictedUserRoute.extend({
|
|||||||
Discourse.PreferencesIndexRoute = Discourse.RestrictedUserRoute.extend({
|
Discourse.PreferencesIndexRoute = Discourse.RestrictedUserRoute.extend({
|
||||||
renderTemplate: function() {
|
renderTemplate: function() {
|
||||||
this.render('preferences', { into: 'user', outlet: 'userOutlet', controller: 'preferences' });
|
this.render('preferences', { into: 'user', outlet: 'userOutlet', controller: 'preferences' });
|
||||||
},
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -504,7 +504,7 @@ Discourse.ComposerView = Discourse.View.extend(Ember.Evented, {
|
|||||||
var $uploadTarget = $('#reply-control');
|
var $uploadTarget = $('#reply-control');
|
||||||
$uploadTarget.fileupload('destroy');
|
$uploadTarget.fileupload('destroy');
|
||||||
$uploadTarget.off();
|
$uploadTarget.off();
|
||||||
},
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// not sure if this is the right way, keeping here for now, we could use a mixin perhaps
|
// not sure if this is the right way, keeping here for now, we could use a mixin perhaps
|
||||||
|
@ -7,4 +7,4 @@ I18n.pluralizationRules['cs'] = function (n) {
|
|||||||
if (n == 1) return "one";
|
if (n == 1) return "one";
|
||||||
if (n >= 2 && n <= 4) return "few";
|
if (n >= 2 && n <= 4) return "few";
|
||||||
return "other";
|
return "other";
|
||||||
}
|
};
|
||||||
|
@ -7,4 +7,4 @@ I18n.pluralizationRules['ru'] = function (n) {
|
|||||||
if (n % 10 == 1 && n % 100 != 11) return "one";
|
if (n % 10 == 1 && n % 100 != 11) return "one";
|
||||||
if (n % 10 >= 2 && n % 10 <= 4 && (n % 100 < 10 || n % 100 >= 20)) return "few";
|
if (n % 10 >= 2 && n % 10 <= 4 && (n % 100 < 10 || n % 100 >= 20)) return "few";
|
||||||
return "many";
|
return "many";
|
||||||
}
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user