seanlixu / CITS3403-RequestBoard

Job/ service request board project for CITS3403
MIT License
1 stars 0 forks source link

routes.py and login.py clash #17

Closed SeanLixu23445997 closed 6 months ago

SeanLixu23445997 commented 6 months ago

when inputting correct login details, it wont go through the proper logic defined in the login.py file. I think its due to the fact that there are two endpoints being defined with the same endpoint name login(). to mitigate this, I suggest combining login.py and register.py

OR

instead, remove the "post" from methods=["GET", "POST"] Inside of routes. ( i have no idea if this will work, but ill give a try)

V this is from login.py Screenshot 2024-05-08 at 4 37 08 pm

V this is from routes.py Screenshot 2024-05-08 at 4 36 54 pm

SeanLixu23445997 commented 6 months ago

adding the login.py to the routes.py seems to work

paulmmaingi commented 6 months ago

I am in the process of refactoring the backend code in order to modularise the authentication and use handlers for logging in and out.