diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb index 9bf5160..2f92c18 100755 --- a/app/controllers/users_controller.rb +++ b/app/controllers/users_controller.rb @@ -72,7 +72,7 @@ class UsersController < ApplicationController def generate_token(id, email) hash = Digest::MD5.hexdigest(email) - "#{id}~#{hash}" + "#{id}-#{hash}" end end diff --git a/config/environments/development.rb b/config/environments/development.rb index 9db258d..27e657b 100755 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -34,7 +34,11 @@ Railsgoat::Application.configure do # Expands the lines which load the assets config.assets.debug = true - + + # ActionMailer settings for email support + config.action_mailer.delivery_method = :smtp + config.action_mailer.smtp_settings = { :address => "localhost", :port => 1025 } + config.middleware.insert_before( Rack::Lock, Rack::LiveReload, :min_delay => 500, diff --git a/config/initializers/smtp_settings.rb b/config/initializers/smtp_settings.rb deleted file mode 100644 index ecb0901..0000000 --- a/config/initializers/smtp_settings.rb +++ /dev/null @@ -1,9 +0,0 @@ -ActionMailer::Base.smtp_settings = { - :address => 'mailtrap.io', - :port => 2525, - :authentication => :plain, - :user_name => ENV['MAILTRAP_USERNAME'], - :password => ENV['MAILTRAP_PASSWORD'] -} - -ActionMailer::Base.delivery_method = :smtp \ No newline at end of file