maxdobeck / gatekeeper

API that performs user authentication and authorization as well as process business logic.
0 stars 0 forks source link

Delete Member and All Member Data #37

Open maxdobeck opened 6 years ago

maxdobeck commented 6 years ago

https://www.postgresql.org/docs/current/static/ddl-constraints.html#DDL-CONSTRAINTS-FK

Use ON DELETE CASCADE for anything referenced by the member_id.

Looks like this may be the best way going forward. If a member is deleted everything is lost. All records.

maxdobeck commented 6 years ago

Currently if you delete a member at the DB level their data goes with them by using cascade delete. At this point we just need to trigger log the user out and trigger it via the UI button.