Module: Authentication::InstanceMethods
- Included in:
- Saasaparilla::Admin::PlansController, Saasaparilla::Admin::SubscriptionsController, Saasaparilla::Admin::TransactionsController, Saasaparilla::BillingHistoryController, Saasaparilla::ContactInfoController, Saasaparilla::CreditCardController, Saasaparilla::InvoicesController, Saasaparilla::PaymentsController, Saasaparilla::PlansController, Saasaparilla::SubscriptionController
- Defined in:
- lib/saasaparilla/authentication.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.included(base) ⇒ Object
6 7 8 |
# File 'lib/saasaparilla/authentication.rb', line 6 def self.included(base) base.before_filter :require_current_billable end |
Instance Method Details
#require_current_billable ⇒ Object
11 12 13 14 15 16 |
# File 'lib/saasaparilla/authentication.rb', line 11 def require_current_billable if current_billable.nil? flash[:error] = "You must be logged in first." redirect_to '/' end end |