initial commit

This commit is contained in:
Alex Holliday committed 2025-11-13 13:47:26 -08:00
1 parent 7cb985116e
commit 75acf7b38f
955 files changed
+37333 -87054

No files matched your search

+33
View File
@@ -0,0 +1,33 @@
import { Router } from "express";
import { RecoveryController } from "@/controllers/index.js";
import { validateBody } from "@/middleware/validation.js";
import { recoverySchema, resetPasswordSchema } from "@/validation/index.js";
class RecoveryRoutes {
private router;
private controller;
constructor(recoveryController: RecoveryController) {
this.router = Router();
this.controller = recoveryController;
this.initRoutes();
}
initRoutes = () => {
this.router.post(
"/",
validateBody(recoverySchema),
this.controller.requestRecovery
);
this.router.post(
"/reset",
validateBody(resetPasswordSchema),
this.controller.resetPassword
);
};
getRouter() {
return this.router;
}
}
export default RecoveryRoutes;