嘿,我在 omniauth 上观看以下 railscast,想知道使用 是否uid
是存储会话的正确方法。存储凭证令牌不是更安全吗?
http://railscasts.com/episodes/241-simple-omniauth
我有以下架构,并希望能够从 facebook 创建新用户。关于如何正确执行此操作的任何想法?
Column | Type | Modifiers
------------------------+-----------------------------+----------------------------------------------------
id | integer | not null default nextval('users_id_seq'::regclass)
first_name | character varying(255) |
last_name | character varying(255) |
email | character varying(255) |
created_at | timestamp without time zone | not null
updated_at | timestamp without time zone | not null
password_digest | character varying(255) |
remember_token | character varying(255) |
admin | boolean | default false
password_reset_token | character varying(255) |
password_reset_sent_at | timestamp without time zone |