Skip to content

Instantly share code, notes, and snippets.

@mikecmpbll
Created February 26, 2015 14:46
Show Gist options
  • Save mikecmpbll/a29d2fb1655314a80e82 to your computer and use it in GitHub Desktop.
Save mikecmpbll/a29d2fb1655314a80e82 to your computer and use it in GitHub Desktop.
class ApplicationController < ActionController::Base
end
class SharedController < ApplicationController
before_action :foo
before_action :bar
def foo
#stub
end
def bar
#stub
end
end
class OtherController < SharedController
# inherits the actions from SharedController
end
class AnotherConrtoller < ApplicationController
# doesn't inherit the actions
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment