Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixing errors

  • Loading branch information...
commit 9e2beb8bccd6ce344af7670b39e65b945a9ae952 1 parent f00fb0e
@arieliten arieliten authored
View
13 app/controllers/password_resets_controller.rb
@@ -2,7 +2,8 @@ class PasswordResetsController < ApplicationController
skip_before_filter :require_user
before_filter :require_no_user
before_filter :load_user_using_perishable_token, :only => [:edit, :update]
-
+
+
def new
end
@@ -18,7 +19,6 @@ def create
render :action => :new
end
end
-
def edit
@@ -26,7 +26,7 @@ def edit
def update
@user.password = params[:user][:password]
- @user.password_confirmation = params[:user][: password_confirmation]
+ @user.password_confirmation = params[:user][:password_confirmation]
if @user.save
flash[:notice] = "Password successfully updated"
redirect_to account_url
@@ -35,8 +35,10 @@ def update
end
end
+
+
private
-
+
def load_user_using_perishable_token
@user = User.find_using_perishable_token(params[:id])
unless @user
@@ -47,6 +49,5 @@ def load_user_using_perishable_token
redirect_to root_url
end
end
-
-
+
end
View
8 config/initializers/middleware.rb
@@ -1,8 +0,0 @@
-require "rack/bug"
-
-ActionController::Dispatcher.middleware.use Rack::Bug,
- :ip_masks => [IPAddr.new("127.0.0.1")],
- :secret_key => "9dloOeAPG6YWazchlsHCeR9dloOeAPG6YWazuH2sTUZzQ4yWY+8z1",
- :password => "openoverflow",
- :data_store_url => 'http://localhost:3298/reports',
- :data_store_key => 'openoverflow123'
Please sign in to comment.
Something went wrong with that request. Please try again.