Sha256: 8f7f862fe1eed2ed1725ae820488df7842f382d2d3fb43eb62151900057935a9
Contents?: true
Size: 929 Bytes
Versions: 2
Compression:
Stored size: 929 Bytes
Contents
module Boilerman module Checks # Return controllers that don't have inheritance_controller in it's # ancestor list. This method defaults to checking for ApplicationController. def self.inheritance_check(inheritance_controller="ApplicationController") inheritance_controller = inheritance_controller.constantize # On top of rejecting controllers which do not have the passed in # inheritance_controller, we also want to reject ActionController::Base # as this won't be a useful result (at least I don't think it will be) Boilerman.controllers.reject do |controller| controller.ancestors.include?(inheritance_controller) || controller == ActionController::Base end end def self.csrf_check Boilerman::Actions.get_action_hash.select do |controller, actions| #TODO implement verify_authenticity_token filter checking logic end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
boilerman-0.1.2 | lib/boilerman/checks.rb |
boilerman-0.1.1 | lib/boilerman/checks.rb |