Secure product_categories and add example test for other supplier resources and fix hack attempts included in test
This commit is contained in:
@@ -1,10 +1,9 @@
|
||||
class ApplicationController < ActionController::Base
|
||||
before_filter :set_locale
|
||||
layout :layout_by_resource
|
||||
|
||||
|
||||
protect_from_forgery
|
||||
|
||||
rescue_from SimplyStored::RecordNotFound, with: :show_404
|
||||
private
|
||||
|
||||
def broadcast_user(uid, event, data = {})
|
||||
@@ -62,4 +61,8 @@ private
|
||||
"http://#{Rails.env.production? ? 'events.qwaiter.com' : 'localhost'}:9296/faye"
|
||||
end
|
||||
helper_method :event_host
|
||||
|
||||
def show_404
|
||||
render 'dashboard/404', layout: true, status: 404
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user