-
Notifications
You must be signed in to change notification settings - Fork 143
feat: add id_type in logins table
#181
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add id_type in logins table
#181
Conversation
5490399 to
4612b1f
Compare
MGatner
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this better than the prefixes. A few suggestions.
4612b1f to
a73621e
Compare
Co-authored-by: MGatner <mgatner@icloud.com>
194a0f5 to
edd3510
Compare
No need to worry about operator precedence.
| 'id' => ['type' => 'int', 'constraint' => 11, 'unsigned' => true, 'auto_increment' => true], | ||
| 'ip_address' => ['type' => 'varchar', 'constraint' => 255], | ||
| 'user_agent' => ['type' => 'varchar', 'constraint' => 255, 'null' => true], | ||
| 'id_type' => ['type' => 'varchar', 'constraint' => 255], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same thing for here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
MGatner
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
Need to rebase after merging #177Identifiers can be added, and it will be not possible to determine what they are just from the identifier string.
Currently,
token:is also added to access tokens.Also, if there is no constraint, it is not possible to tell whether it is an
emailor ausernamejust from the string.It is easier to know what it is if we add a column for identifier type.
id_typeinauth_loginsandauth_token_loginsemail_password,username,magic-link, andaccess_tokenCheckQueryReturnTraitID_TYPE_*inSessionandAccessTokens