Skip to content

Instantly share code, notes, and snippets.

@gavinhughes
Created January 6, 2012 02:12
Show Gist options
  • Save gavinhughes/1568581 to your computer and use it in GitHub Desktop.
Save gavinhughes/1568581 to your computer and use it in GitHub Desktop.
[1] pry(#<ProfilesController>)> @user = current_user.dup
=> #<Sponsor _id: 4f065814421aa90df800001a, _type: "Sponsor", created_at: 2012-01-06 02:02:01 UTC, updated_at: 2012-01-06 02:03:25 UTC, email: "[email protected]", encrypted_password: "$2a$10$/ondEoQsfgQ2yzMCW8qasOTLdqJTszzHLH6Ice6wOwTV7yTJuncUe", reset_password_token: nil, reset_password_sent_at: nil, remember_created_at: nil, sign_in_count: 1, current_sign_in_at: 2012-01-06 02:02:15 UTC, last_sign_in_at: 2012-01-06 02:02:15 UTC, current_sign_in_ip: "127.0.0.1", last_sign_in_ip: "127.0.0.1", confirmation_token: nil, confirmed_at: 2012-01-06 02:02:08 UTC, confirmation_sent_at: 2012-01-06 02:02:01 UTC, unconfirmed_email: nil, first_name: nil, last_name: nil, nickname: "Gavin", gender: nil, birthdate: 2002-02-02 00:00:00 UTC, preferred_relationship_types: [""], statement: "", first_specified_birthdate: 2002-02-02 00:00:00 UTC>
[2] pry(#<ProfilesController>)> current_user.reload
=> #<Sponsor _id: 4f065619421aa90df8000011, _type: "Sponsor", created_at: 2012-01-06 02:02:01 UTC, updated_at: 2012-01-06 02:03:25 UTC, email: "[email protected]", encrypted_password: "$2a$10$/ondEoQsfgQ2yzMCW8qasOTLdqJTszzHLH6Ice6wOwTV7yTJuncUe", reset_password_token: nil, reset_password_sent_at: nil, remember_created_at: nil, sign_in_count: 1, current_sign_in_at: 2012-01-06 02:02:15 UTC, last_sign_in_at: 2012-01-06 02:02:15 UTC, current_sign_in_ip: "127.0.0.1", last_sign_in_ip: "127.0.0.1", confirmation_token: nil, confirmed_at: 2012-01-06 02:02:08 UTC, confirmation_sent_at: 2012-01-06 02:02:01 UTC, unconfirmed_email: nil, first_name: nil, last_name: nil, nickname: "Gavin", gender: nil, birthdate: 2002-02-02 00:00:00 UTC, preferred_relationship_types: [""], statement: "", first_specified_birthdate: 2002-02-02 00:00:00 UTC>
[3] pry(#<ProfilesController>)> User.count
=> 1
[4] pry(#<ProfilesController>)> @user.valid?
=> false
[5] pry(#<ProfilesController>)> User.count
=> 2
[6] pry(#<ProfilesController>)>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment