generated from hackforla/.github-hackforla-base-repo-template
-
-
Notifications
You must be signed in to change notification settings - Fork 97
Closed
Labels
complexity: smallp-feature: Loginrole: Back Endsize: 0.5ptCan be done in 2-3 hours or lessCan be done in 2-3 hours or less
Milestone
Description
Overview
It was previously possible to create multiple users in the db with the same email if the email was input with inconsistent casing (e.g. [email protected] vs. [email protected]). .toLowerCase() has been added in multiple places to prevent this from happening, but as a final safety/sanity check, adding lowercase: true to the userSchema in the backend should ensure that a user document is never stored with capital characters.
Action Items
- Add
lowercase: truetouserSchemainbackend/models/user.model.js - Add test to
backend/models/user.model.test.jsfor the lowercasing of emails
Resources/Instructions
Mongoose Docs
This is issue is a part of the epic: #1456
Metadata
Metadata
Assignees
Labels
complexity: smallp-feature: Loginrole: Back Endsize: 0.5ptCan be done in 2-3 hours or lessCan be done in 2-3 hours or less
Type
Projects
Status
Final QA (product)