amczuboka / Decagon-CondoManagementSystem

Condo Management System
3 stars 3 forks source link

Prevent user from logging in if they don't have a node in the realtime database #182

Closed Guillaume-Lachapelle closed 5 months ago

Guillaume-Lachapelle commented 6 months ago

In the scenario where a company deletes an employee, their node will be removed from the realtime database but we will keep their user in the authentication. This way, upon login, we will check if the user from the realtime database exists. If it exists, then go to landing, otherwise sign out the user and/or redirect to an empty page saying their account was suspended, and block their access to every page in the website.