Displaying 4 results from an estimated 4 matches for "password_digest".
2013 May 19
5
update_attributes() for a single column
...ECT "users".* FROM "users" ORDER BY
"users"."id" ASC LIMIT 1
=> #<User id: 1, name: "Michael Hartl", email: "foo-+RB1Aph5k6s@public.gmane.org",
created_at: "2013-05-12 12:47:23", updated_at: "2013-05-12 13:24:26",
password_digest: "$2a
$10$CYZFddDa5Glv0dlYhlpZguIuzfyMRiwleaenmh67hFyK...">
irb(main):005:0> user.update_attributes(email:
''example-S0P6GYPhS/5I9/98DSiCMdi2O/JbrIOy@public.gmane.org'')
(2.1ms) BEGIN
User Exists (4.2ms) SELECT 1 AS one FROM "users" WHERE
(LOWER(&quo...
2012 May 13
4
undefined method `key?' for nil:NilClass,bcrypt-ruby,has_secure_password
I''m going through DHH''s Agile Web Development with Rails for Rails 3.1. In
chapter 14 they create a Users sign-in model/view/controller using the
has_secure_password method. My user.rb file looks like this
class User < ActiveRecord::Base
attr_accessible :name, :password_digest, :password, :password_confirmation
validates :name, presence: true, uniqueness: true
has_secure_password
end
now when I go to localhost:3000/users/new I first get some kind of
bcrypt-ruby error and then when I reload the page I get a undefined method
`key?'' for nil:NilCl...
2012 Mar 06
2
rails login page with basic authorization
i have 2 portal, one and two. The portal one have all apis, and the portal
Two have the interfaces, Here just i am doing enter the username and
password in the login page so that will go the method of Portal Two. Then
it will pass the username and password of a method of Portal One, this is
am doing here. My question is how to do the basic authorization for encrypt
the username and password
2012 May 24
0
Ruby on Rails Tutorial Chapter 6 RSpec tests failing
...Examplexxx", email: "user-hcDgGtZH8xNBDgjK7y7TUQ@public.gmane.org",
password: "foobar", password_confirmation:
"foobar")
end
subject { @user }
it { should respond_to(:name) }
it { should respond_to(:email) }
it { should respond_to(:password_digest) }
it { should respond_to(:password) }
it { should respond_to(:password_confirmation) }
it { should respond_to(:authenticate) }
it { should be_valid }
describe "when name is not present" do
before { @user.name = " " }
it { should_not be_valid }
end
descr...