Skip to content

Instantly share code, notes, and snippets.

@sj26
Forked from dangalipo/controller.rb
Created May 19, 2011 02:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sj26/980105 to your computer and use it in GitHub Desktop.
Save sj26/980105 to your computer and use it in GitHub Desktop.
def destroy
authorize! :destroy, @health_professional
@health_professional.destroy
respond_with :manage, @health_professional
end
@sj26
Copy link
Author

sj26 commented May 19, 2011

@dangalipo: this should do the same thing. Makes it easier when all your respond_with lines are just prefixed like your controllers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment