-
Notifications
You must be signed in to change notification settings - Fork 13
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
Add CRUD functions for models via Prisma #228
Conversation
I tried to rebase my topic branch because there was some issue with history not matching, when I attempted to make changes from feedback. |
I think a bunch of other (not your) changes are showing up after the rebase. This is most likely because you did not force push after the rebase. |
* For model: User, Record, Certificate, Challenge * deleteUserByEmail() changes to deleteUserByUsername
01e8fa9
to
a7ee458
Compare
Yeah, I accidently synced the wrong branch to upstream's main, which caused the history mismatch. |
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 only have a nitpick which is the use of id
, but otherwise the pr looks great!
I hear you. I still think it's more useful to use |
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.
The comment for createCertificate
might also apply on createChallenge
and createRecord
though I have only tested it for createCertificate
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 tested all these methods locally; looks great!
Can you file an issue to add test for this code?
Sure. |
Done |
Relates to #97
Changes:
deleteUserByEmail()
changes todeleteUserByUsername()
Test:
NOTE:
npx ts-node
needs to have--require tsconfig-paths/register
or it won't understand~
for paths( todb.bserver
andlogger.server
) in our project.npm run db:studio
can let you view data in database after an operation.