diff --git a/app/assets/javascripts/admin/models/admin-user.js.es6 b/app/assets/javascripts/admin/models/admin-user.js.es6 index ec230ffff48..39a2b7ee1dd 100644 --- a/app/assets/javascripts/admin/models/admin-user.js.es6 +++ b/app/assets/javascripts/admin/models/admin-user.js.es6 @@ -530,14 +530,11 @@ const AdminUser = Discourse.User.extend({ } }, - @computed("suspended_by") - suspendedBy: wrapAdmin, + @computed("suspended_by") suspendedBy: wrapAdmin, - @computed("silenced_by") - silencedBy: wrapAdmin, + @computed("silenced_by") silencedBy: wrapAdmin, - @computed("approved_by") - approvedBy: wrapAdmin + @computed("approved_by") approvedBy: wrapAdmin }); AdminUser.reopenClass({ diff --git a/app/assets/javascripts/discourse/components/backup-codes.js.es6 b/app/assets/javascripts/discourse/components/backup-codes.js.es6 index 3df4b064b98..11457eb7369 100644 --- a/app/assets/javascripts/discourse/components/backup-codes.js.es6 +++ b/app/assets/javascripts/discourse/components/backup-codes.js.es6 @@ -31,8 +31,7 @@ export default Ember.Component.extend({ } }, - @computed("formattedBackupCodes") - base64BackupCode: b64EncodeUnicode, + @computed("formattedBackupCodes") base64BackupCode: b64EncodeUnicode, @computed("backupCodes") formattedBackupCodes(backupCodes) { diff --git a/app/assets/javascripts/discourse/components/d-navigation.js.es6 b/app/assets/javascripts/discourse/components/d-navigation.js.es6 index dc1eee1c3c7..0ba2a852017 100644 --- a/app/assets/javascripts/discourse/components/d-navigation.js.es6 +++ b/app/assets/javascripts/discourse/components/d-navigation.js.es6 @@ -18,8 +18,7 @@ export default Ember.Component.extend({ return hasDraft ? "topic.open_draft" : "topic.create"; }, - @computed("category.can_edit") - showCategoryEdit: canEdit => canEdit, + @computed("category.can_edit") showCategoryEdit: canEdit => canEdit, @computed("filterMode", "category", "noSubcategories") navItems(filterMode, category, noSubcategories) { diff --git a/app/assets/javascripts/discourse/components/group-post.js.es6 b/app/assets/javascripts/discourse/components/group-post.js.es6 index f94f36dc8db..5a28daf92dd 100644 --- a/app/assets/javascripts/discourse/components/group-post.js.es6 +++ b/app/assets/javascripts/discourse/components/group-post.js.es6 @@ -1,6 +1,5 @@ import computed from "ember-addons/ember-computed-decorators"; export default Ember.Component.extend({ - @computed("post.url") - postUrl: Discourse.getURL + @computed("post.url") postUrl: Discourse.getURL }); diff --git a/app/assets/javascripts/discourse/components/topic-entrance.js.es6 b/app/assets/javascripts/discourse/components/topic-entrance.js.es6 index 216f024fc60..997171aa97d 100644 --- a/app/assets/javascripts/discourse/components/topic-entrance.js.es6 +++ b/app/assets/javascripts/discourse/components/topic-entrance.js.es6 @@ -32,11 +32,9 @@ export default Ember.Component.extend(CleansUp, { topic: null, visible: null, - @computed("topic.created_at") - createdDate: createdAt => new Date(createdAt), + @computed("topic.created_at") createdDate: createdAt => new Date(createdAt), - @computed("topic.bumped_at") - bumpedDate: bumpedAt => new Date(bumpedAt), + @computed("topic.bumped_at") bumpedDate: bumpedAt => new Date(bumpedAt), @computed("createdDate", "bumpedDate") showTime(createdDate, bumpedDate) { diff --git a/app/assets/javascripts/discourse/controllers/composer.js.es6 b/app/assets/javascripts/discourse/controllers/composer.js.es6 index f3f26754901..870f60b854e 100644 --- a/app/assets/javascripts/discourse/controllers/composer.js.es6 +++ b/app/assets/javascripts/discourse/controllers/composer.js.es6 @@ -287,8 +287,7 @@ export default Ember.Controller.extend({ return authorizesOneOrMoreExtensions(); }, - @computed() - uploadIcon: () => uploadIcon(), + @computed() uploadIcon: () => uploadIcon(), actions: { cancelUpload() { diff --git a/app/assets/javascripts/discourse/controllers/static.js.es6 b/app/assets/javascripts/discourse/controllers/static.js.es6 index 8238d5fad9f..6d3cbd2df15 100644 --- a/app/assets/javascripts/discourse/controllers/static.js.es6 +++ b/app/assets/javascripts/discourse/controllers/static.js.es6 @@ -7,8 +7,7 @@ export default Ember.Controller.extend({ showLoginButton: Em.computed.equal("model.path", "login"), - @computed("model.path") - bodyClass: path => `static-${path}`, + @computed("model.path") bodyClass: path => `static-${path}`, @computed("model.path") showSignupButton() { diff --git a/app/assets/javascripts/discourse/controllers/upload-selector.js.es6 b/app/assets/javascripts/discourse/controllers/upload-selector.js.es6 index b22674657bc..918128d0c23 100644 --- a/app/assets/javascripts/discourse/controllers/upload-selector.js.es6 +++ b/app/assets/javascripts/discourse/controllers/upload-selector.js.es6 @@ -25,11 +25,9 @@ export default Ember.Controller.extend(ModalFunctionality, { remote: Ember.computed.equal("selection", "remote"), selection: "local", - @computed() - uploadIcon: () => uploadIcon(), + @computed() uploadIcon: () => uploadIcon(), - @computed() - title: () => uploadTranslate("title"), + @computed() title: () => uploadTranslate("title"), @computed("selection") tip(selection) { diff --git a/app/assets/javascripts/discourse/models/composer.js.es6 b/app/assets/javascripts/discourse/models/composer.js.es6 index 801b44c24c4..753c9bf7413 100644 --- a/app/assets/javascripts/discourse/models/composer.js.es6 +++ b/app/assets/javascripts/discourse/models/composer.js.es6 @@ -75,8 +75,7 @@ const Composer = RestModel.extend({ return this.site.get("archetypes"); }.property(), - @computed("action") - sharedDraft: action => action === CREATE_SHARED_DRAFT, + @computed("action") sharedDraft: action => action === CREATE_SHARED_DRAFT, @computed categoryId: { @@ -134,8 +133,7 @@ const Composer = RestModel.extend({ topicFirstPost: Em.computed.or("creatingTopic", "editingFirstPost"), - @computed("action") - editingPost: isEdit, + @computed("action") editingPost: isEdit, replyingToTopic: Em.computed.equal("action", REPLY), diff --git a/app/assets/javascripts/discourse/models/nav-item.js.es6 b/app/assets/javascripts/discourse/models/nav-item.js.es6 index 6a9a782aeaf..ad4c0b16952 100644 --- a/app/assets/javascripts/discourse/models/nav-item.js.es6 +++ b/app/assets/javascripts/discourse/models/nav-item.js.es6 @@ -105,8 +105,7 @@ const NavItem = Discourse.Model.extend({ }); const ExtraNavItem = NavItem.extend({ - @computed("href") - href: href => href, + @computed("href") href: href => href, customFilter: null }); diff --git a/app/assets/javascripts/discourse/models/user.js.es6 b/app/assets/javascripts/discourse/models/user.js.es6 index 94f972ca27a..74f103e551a 100644 --- a/app/assets/javascripts/discourse/models/user.js.es6 +++ b/app/assets/javascripts/discourse/models/user.js.es6 @@ -198,17 +198,13 @@ const User = RestModel.extend({ return suspendedTill && moment(suspendedTill).isAfter(); }, - @computed("suspended_till") - suspendedForever: isForever, + @computed("suspended_till") suspendedForever: isForever, - @computed("silenced_till") - silencedForever: isForever, + @computed("silenced_till") silencedForever: isForever, - @computed("suspended_till") - suspendedTillDate: longDate, + @computed("suspended_till") suspendedTillDate: longDate, - @computed("silenced_till") - silencedTillDate: longDate, + @computed("silenced_till") silencedTillDate: longDate, changeUsername(new_username) { return ajax( diff --git a/app/assets/javascripts/wizard/components/staff-count.js.es6 b/app/assets/javascripts/wizard/components/staff-count.js.es6 index 7677d999dea..17df6043d1c 100644 --- a/app/assets/javascripts/wizard/components/staff-count.js.es6 +++ b/app/assets/javascripts/wizard/components/staff-count.js.es6 @@ -1,6 +1,5 @@ import computed from "ember-addons/ember-computed-decorators"; export default Ember.Component.extend({ - @computed("field.value") - showStaffCount: staffCount => staffCount > 1 + @computed("field.value") showStaffCount: staffCount => staffCount > 1 }); diff --git a/app/assets/javascripts/wizard/components/wizard-step-form.js.es6 b/app/assets/javascripts/wizard/components/wizard-step-form.js.es6 index a60d5b39cb4..ff2919bebb1 100644 --- a/app/assets/javascripts/wizard/components/wizard-step-form.js.es6 +++ b/app/assets/javascripts/wizard/components/wizard-step-form.js.es6 @@ -3,6 +3,5 @@ import computed from "ember-addons/ember-computed-decorators"; export default Ember.Component.extend({ classNameBindings: [":wizard-step-form", "customStepClass"], - @computed("step.id") - customStepClass: stepId => `wizard-step-${stepId}` + @computed("step.id") customStepClass: stepId => `wizard-step-${stepId}` }); diff --git a/app/assets/javascripts/wizard/components/wizard-step.js.es6 b/app/assets/javascripts/wizard/components/wizard-step.js.es6 index 4732548e8d7..d5fb39af769 100644 --- a/app/assets/javascripts/wizard/components/wizard-step.js.es6 +++ b/app/assets/javascripts/wizard/components/wizard-step.js.es6 @@ -31,8 +31,7 @@ export default Ember.Component.extend({ this.autoFocus(); }, - @computed("step.index") - showQuitButton: index => index === 0, + @computed("step.index") showQuitButton: index => index === 0, @computed("step.displayIndex", "wizard.totalSteps") showNextButton: (current, total) => current < total, @@ -40,8 +39,7 @@ export default Ember.Component.extend({ @computed("step.displayIndex", "wizard.totalSteps") showDoneButton: (current, total) => current === total, - @computed("step.index") - showBackButton: index => index > 0, + @computed("step.index") showBackButton: index => index > 0, @computed("step.banner") bannerImage(src) { diff --git a/app/assets/javascripts/wizard/mixins/valid-state.js.es6 b/app/assets/javascripts/wizard/mixins/valid-state.js.es6 index ee00842eace..cd3faa5e696 100644 --- a/app/assets/javascripts/wizard/mixins/valid-state.js.es6 +++ b/app/assets/javascripts/wizard/mixins/valid-state.js.es6 @@ -15,14 +15,11 @@ export default { this.set("_validState", States.UNCHECKED); }, - @computed("_validState") - valid: state => state === States.VALID, + @computed("_validState") valid: state => state === States.VALID, - @computed("_validState") - invalid: state => state === States.INVALID, + @computed("_validState") invalid: state => state === States.INVALID, - @computed("_validState") - unchecked: state => state === States.UNCHECKED, + @computed("_validState") unchecked: state => state === States.UNCHECKED, setValid(valid, description) { this.set("_validState", valid ? States.VALID : States.INVALID); diff --git a/app/assets/javascripts/wizard/models/step.js.es6 b/app/assets/javascripts/wizard/models/step.js.es6 index d465b553b46..fc1d0ac1f5c 100644 --- a/app/assets/javascripts/wizard/models/step.js.es6 +++ b/app/assets/javascripts/wizard/models/step.js.es6 @@ -5,8 +5,7 @@ import { ajax } from "wizard/lib/ajax"; export default Ember.Object.extend(ValidState, { id: null, - @computed("index") - displayIndex: index => index + 1, + @computed("index") displayIndex: index => index + 1, @computed("fields.[]") fieldsById(fields) { diff --git a/app/assets/javascripts/wizard/models/wizard.js.es6 b/app/assets/javascripts/wizard/models/wizard.js.es6 index d83ba58ef00..95fa48bfb03 100644 --- a/app/assets/javascripts/wizard/models/wizard.js.es6 +++ b/app/assets/javascripts/wizard/models/wizard.js.es6 @@ -4,8 +4,7 @@ import { ajax } from "wizard/lib/ajax"; import computed from "ember-addons/ember-computed-decorators"; const Wizard = Ember.Object.extend({ - @computed("steps.length") - totalSteps: length => length, + @computed("steps.length") totalSteps: length => length, getTitle() { const titleStep = this.get("steps").findBy("id", "forum-title"); diff --git a/package.json b/package.json index 2f0744c03db..0fc51ebb720 100644 --- a/package.json +++ b/package.json @@ -11,7 +11,7 @@ "chrome-launcher": "^0.10.2", "chrome-remote-interface": "^0.25.6", "eslint": "^4.19.1", - "prettier": "^1.14.0", + "prettier": "^1.13.0", "puppeteer": "^1.4.0" } } diff --git a/yarn.lock b/yarn.lock index ae7b736cce3..d908e1a0967 100644 --- a/yarn.lock +++ b/yarn.lock @@ -813,9 +813,9 @@ prelude-ls@~1.1.2: version "1.1.2" resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" -prettier@^1.14.0: - version "1.14.0" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.14.0.tgz#847c235522035fd988100f1f43cf20a7d24f9372" +prettier@1.13.4: + version "1.13.4" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.13.4.tgz#31bbae6990f13b1093187c731766a14036fa72e6" process-nextick-args@~1.0.6: version "1.0.7"