Skip to content

Deleting a parent entity results in orphaned child entities. #1

@ghost

Description

Say I have a structure where post1 is dependent on comment1, comment2, and comment3.

  • If I delete post1, I'd want to also get rid of comment1, comment2, and comment3, as they would no longer be used. But instead, here, they'd linger on, unneeded, clogging up my Stash.
  • However, if, somehow, a post2 also depended on comment1, I'd want to not delete it along with post1, as long as something still referenced it.

My idea would be to mark certain entities as delete-if-orphaned, and, when an entity depending on them is deleted/invalidated, they would also be removed. Not sure if that's the best way to go about this, though.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions