Skip to content

Feature delete user complete#40

Merged
Vasilijez merged 8 commits into
developfrom
feature-delete-user-complete
Oct 29, 2025
Merged

Feature delete user complete#40
Vasilijez merged 8 commits into
developfrom
feature-delete-user-complete

Conversation

@Vasilijez

@Vasilijez Vasilijez commented Oct 28, 2025

Copy link
Copy Markdown
Member

Closes #6

My biggest difficulty was determining which APIs should include a logical deletion check, whether for user deletion or room deletion. Ideally, all APIs should be updated, but I wasn’t entirely sure about that, as it would require many changes and I was concerned about dependencies. Therefore, I focused on the APIs that are directly exposed by the webapp.

I am ready to update all APIs, or specific ones if necessary or as you recommend.

Part of:

@sonarqubecloud

sonarqubecloud Bot commented Oct 28, 2025

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
0.0% Coverage on New Code (required ≥ 80%)
17.2% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

@magley

magley commented Oct 28, 2025

Copy link
Copy Markdown
Member

Scenario:

  • Host H has a room R
  • Guest G creates a reservation request for R
  • H deletes his account
  • This passes, but the reservation request for R is not deleted
  • In the web app, G can see this request and click the link to room R, which has been deleted

@Vasilijez

Copy link
Copy Markdown
Member Author

Scenario:

  • Host H has a room R
  • Guest G creates a reservation request for R
  • H deletes his account
  • This passes, but the reservation request for R is not deleted
  • In the web app, G can see this request and click the link to room R, which has been deleted

Okay, I made some changes related to this in other PRs. Please test it carefully.

@magley magley left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't the FindById method return 404 if the user is deleted?

Since we do logical deleting now, it'll return a deleted user. Do you check for deleted users elsewhere? Come to think of it, you do in reservation-service. Should we leave it as-is, then?

@magley magley self-requested a review October 29, 2025 09:46
@Vasilijez

Copy link
Copy Markdown
Member Author

Shouldn't the FindById method return 404 if the user is deleted?

Since we do logical deleting now, it'll return a deleted user. Do you check for deleted users elsewhere? Come to think of it, you do in reservation-service. Should we leave it as-is, then?

I really need to be careful if I do it (and that’s the reason why I skipped it), because it’s a core method and consequently an API that’s used very often. So if we do it, we need to thoroughly check its role everywhere it’s used. For now, most of the APIs that are used by our web app are covered.

@Vasilijez Vasilijez merged commit 587431d into develop Oct 29, 2025
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

User account deletion

2 participants