Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After deleting the entity, the target entity still has incoming links. #13

Closed
Belzebbuz opened this issue Sep 6, 2024 · 3 comments
Closed
Assignees
Labels
bug Something isn't working

Comments

@Belzebbuz
Copy link

This test fail

var store = new EntityStore();
var entityA = store.CreateEntity();
var entityB = store.CreateEntity();
entityA.AddRelation(new Link(entityB));
		
entityA.DeleteEntity();

var incomingLinks = entityB.GetIncomingLinks<Link>();
incomingLinks.Count.Should().Be(0);

private readonly struct Link(Entity target) : ILinkRelation
{
    public Entity GetRelationKey() => target;
}

image

friflo added a commit that referenced this issue Oct 21, 2024
@friflo friflo self-assigned this Oct 21, 2024
@friflo friflo added the bug Something isn't working label Oct 21, 2024
@friflo
Copy link
Owner

friflo commented Oct 21, 2024

add test Test_Relations_GitHub_13
to reproduce bug.

@friflo
Copy link
Owner

friflo commented Oct 24, 2024

@friflo friflo closed this as completed Oct 24, 2024
@friflo
Copy link
Owner

friflo commented Nov 12, 2024

Fixed in 3.0.0-preview.14

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants