From 057d204b874b06c640d62460e1856bea03702f1e Mon Sep 17 00:00:00 2001 From: Rimian Perkins Date: Mon, 13 Mar 2017 11:19:10 +1100 Subject: [PATCH] use let keyword and toggle plugin off by default --- assets/javascripts/discourse/components/stripe-card.js.es6 | 6 +++--- config/settings.yml | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/assets/javascripts/discourse/components/stripe-card.js.es6 b/assets/javascripts/discourse/components/stripe-card.js.es6 index 4689b58..e8062f4 100644 --- a/assets/javascripts/discourse/components/stripe-card.js.es6 +++ b/assets/javascripts/discourse/components/stripe-card.js.es6 @@ -23,7 +23,7 @@ export default Ember.Component.extend({ }, card: function() { - var elements = this.get('stripe').elements(); + let elements = this.get('stripe').elements(); return elements.create('card', { hidePostalCode: this.get('settings').discourse_donations_hide_zip_code }); @@ -36,7 +36,7 @@ export default Ember.Component.extend({ actions: { submitStripeCard() { - var self = this; + let self = this; this.get('stripe').createToken(this.get('card')).then(data => { @@ -48,7 +48,7 @@ export default Ember.Component.extend({ else { self.set('transactionInProgress', true); - var params = { + let params = { stripeToken: data.token.id, amount: self.get('amount') * 100 }; diff --git a/config/settings.yml b/config/settings.yml index 7c5b143..06cd3ad 100644 --- a/config/settings.yml +++ b/config/settings.yml @@ -1,6 +1,6 @@ plugins: discourse_donations_enabled: - default: true + default: false client: true discourse_donations_secret_key: client: false