Sha256: 1a2f723352c8da2963aa17fd04e292aa5aae57a943d9c014e1aeb87b8536938e
Contents?: true
Size: 563 Bytes
Versions: 3
Compression:
Stored size: 563 Bytes
Contents
class UsersController < InheritedResources::Base respond_to :html, :js, :only=>[:edit, :show, :update] respond_to :json, :only=>[:verify_password] before_filter :authenticate_user!, :resource def edit respond_with(resource) end def update update!(:notice=>"Your password has been updated.") {root_url} end def verify respond_with resource do |format| format.json {render :json=> resource.valid_password?(params[:password]).to_json} end end def resource @user ||= FullyValidatedUser.find(current_user) end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
wheels-0.0.47 | app/controllers/users_controller.rb |
wheels-0.0.46 | app/controllers/users_controller.rb |
wheels-0.0.45 | app/controllers/users_controller.rb |