Skip to content

Commit

Permalink
refactor: no need to set definition as internal
Browse files Browse the repository at this point in the history
  • Loading branch information
Dannyps committed Oct 17, 2023
1 parent f8f7e58 commit 0fbf596
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,7 @@ namespace Backbone.Modules.Quotas.Domain.Aggregates.Identities;

public class TierQuota : Quota
{
#pragma warning disable IDE1006 // Naming Styles
internal readonly TierQuotaDefinition _definition;
#pragma warning restore IDE1006 // Naming Styles
private readonly TierQuotaDefinition _definition;

private TierQuota() { }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public void Configure(EntityTypeBuilder<TierQuota> builder)
builder.HasKey(x => x.Id);
builder.ToTable($"{nameof(TierQuota)}s");
builder.Ignore(x => x.Weight);
builder.HasOne(x => x._definition).WithMany().OnDelete(DeleteBehavior.Cascade);
builder.HasOne("_definition").WithMany().OnDelete(DeleteBehavior.Cascade);
builder.Property("_definitionId").HasColumnName("DefinitionId");
builder.Ignore(x => x.DefinitionId);
}
Expand Down

0 comments on commit 0fbf596

Please sign in to comment.