Closed AhmedGarcia closed 1 day ago
Define a User schema with fields: username, email, password, friends, and booksRead.
Include validation and pre-save hooks for password hashing using bcrypt.
Export the model for use in GraphQL resolvers.
Acceptance Criteria: User schema is defined with appropriate fields and validation. Passwords are hashed before saving. Model is exported correctly.
issue completed
Define a User schema with fields: username, email, password, friends, and booksRead.
Include validation and pre-save hooks for password hashing using bcrypt.
Export the model for use in GraphQL resolvers.
Acceptance Criteria: User schema is defined with appropriate fields and validation. Passwords are hashed before saving. Model is exported correctly.