Merge pull request #2 from angusmcleod/suggested_improvements

Include stripe_js && inherit from the application controller
This commit is contained in:
Chris Beach 2017-11-08 08:08:18 +00:00 committed by GitHub
commit a2fac9a4ff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 10 deletions

View File

@ -1,11 +1,7 @@
require_dependency 'discourse'
module DiscourseDonations
class ChargesController < ActionController::Base
include CurrentUser
protect_from_forgery prepend: true
protect_from_forgery with: :exception
class ChargesController < ApplicationController
skip_before_action :verify_authenticity_token, only: [:create]

View File

@ -1,11 +1,7 @@
require_dependency 'discourse'
module DiscourseDonations
class CheckoutController < ActionController::Base
include CurrentUser
protect_from_forgery prepend: true
protect_from_forgery with: :exception
class CheckoutController < ApplicationController
skip_before_action :verify_authenticity_token, only: [:create]

File diff suppressed because one or more lines are too long

View File

@ -9,6 +9,7 @@ gem 'stripe', '2.8.0'
load File.expand_path('../lib/discourse_donations/engine.rb', __FILE__)
register_asset "stylesheets/discourse-donations.css"
register_asset "javascripts/lib/vendor/stripe_v3.js"
enabled_site_setting :discourse_donations_enabled