Skip to content

Commit

Permalink
Merge pull request #96 from TheByteFlow/backend
Browse files Browse the repository at this point in the history
refactor:
  • Loading branch information
muhammedsirajudeen authored Feb 25, 2025
2 parents 99c4d6d + 0bf0b3d commit 6724a71
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 19 deletions.
4 changes: 2 additions & 2 deletions backend/src/controllers/implementation/auth.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export class AuthController implements IAuthController {
try {
const user = await this._authService.signup(req.body);

res.status(200).json({
res.status(HttpStatus.OK).json({
email: user,
});
} catch (err) {
Expand All @@ -31,7 +31,7 @@ export class AuthController implements IAuthController {
sameSite: "strict",
});

res.status(200).json({ accessToken: tokens.accessToken });
res.status(HttpStatus.OK).json({ accessToken: tokens.accessToken });
} catch (err) {
next(err);
}
Expand Down
17 changes: 0 additions & 17 deletions backend/src/models/implementation/user.model.ts
Original file line number Diff line number Diff line change
@@ -1,23 +1,6 @@
import { model, Schema, Document } from "mongoose";
import { IUser } from "shared/types";

// interface IUser {
// _id: string;
// username: string;
// name: string;
// email: string;
// password: string;
// status: "active" | "blocked";
// role: "user" | "moderator";
// bio: string;
// profile_picture?: string;
// social_links: { type: string; url: string }[];
// resume?: string;
// date_of_birth: Date;
// created_at: Date;
// updated_at: Date;
// }

export interface IUserModel extends Document, Omit<IUser, "_id"> {}

const userSchema = new Schema<IUserModel>(
Expand Down

0 comments on commit 6724a71

Please sign in to comment.