Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Plan API architecture
class ApplicationController < ActionController::Base
...
def new
initialize_resource
end
def create
build_resource
resource.save!
end
def update
resource.update! resource_params
end
def destroy
resource.destroy!
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment