plezanje-net / api

NestJS GraphQL web server
GNU General Public License v3.0
7 stars 2 forks source link

Delete user mutation #160

Closed salamca closed 1 year ago

salamca commented 1 year ago

Some module import/export reorganization and other fixes of bugs discovered along.

Adds mutation for deleting the user and all related data. That is:

  1. delete all activities, activity routes, difficulty votes, star rating votes (recalculate difficulty and starRating of routes)
  2. delete all comments
  3. delete all images and image files (from disk)
  4. delete all roles
  5. delete membership in all clubs the user is member of
  6. delete all unpublished contributables (crags, sectors, routes) and unlink user from published ones
  7. Unlink all route events that the user might be associated with

to test: try via postman for a user with all of the above linked entities....

tests added.

ready to merge...