Sha256: e9e25e2436d0e5208aba86adec82a34d72dd66fb691baf740a272d30f553d410
Contents?: true
Size: 603 Bytes
Versions: 10
Compression:
Stored size: 603 Bytes
Contents
class Identity::EmailsController < ApplicationController before_action :require_sudo before_action :set_<%= singular_table_name %> def update if @<%= singular_table_name %>.update(<%= "#{singular_table_name}_params" %>) render json: @<%= singular_table_name %> else render json: @<%= singular_table_name %>.errors, status: :unprocessable_entity end end private def set_<%= singular_table_name %> @<%= singular_table_name %> = Current.<%= singular_table_name %> end def <%= "#{singular_table_name}_params" %> params.permit(:email) end end
Version data entries
10 entries across 10 versions & 1 rubygems