Skip to content

Comments

added authentication#5

Closed
Eniola3321 wants to merge 1 commit intoColabFullstackClass:developfrom
Eniola3321:authController
Closed

added authentication#5
Eniola3321 wants to merge 1 commit intoColabFullstackClass:developfrom
Eniola3321:authController

Conversation

@Eniola3321
Copy link

#closed


// 3) Validate password
const isMatch = await user.comparePassword(password, user.password);
console.log(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove console logs

"outDir": "dist",
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"forceConsistentCasingInFileNames": true,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why did you make updates to the tsconfig

subject: string;
message: string;
}
const sendEmail = async (options: EmailOptions) => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the env variables loaded should come from config and not directly

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why did you delete the env example

} from '../controllers/authController';

const router: Router = Router();
router.route('/signup').post(signUp);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't do it like this, use router.['insert any method there']

//add all them routes here
app.use(rootRoutes); // this contains the routes localhost:port/ and localhost:port/health
app.use('/api', appRoutes);
app.use('/api/v1/users', userRouter);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this isnt how it should be, it should just be /api


// ---------------------- Informational Responses ----------------------
export class Continue extends AppError {
constructor(message = 'Continue', statusCode = 100) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

youre extending too many error codes

@Eniola3321 Eniola3321 closed this by deleting the head repository Sep 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants