From e02e1e120693d466679cae2b602085f57b60971f Mon Sep 17 00:00:00 2001 From: crupest Date: Tue, 11 Aug 2020 01:16:56 +0800 Subject: Make author column of post nullable. --- Timeline/Entities/TimelinePostEntity.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Timeline/Entities/TimelinePostEntity.cs') diff --git a/Timeline/Entities/TimelinePostEntity.cs b/Timeline/Entities/TimelinePostEntity.cs index 24bfc7a3..07367fba 100644 --- a/Timeline/Entities/TimelinePostEntity.cs +++ b/Timeline/Entities/TimelinePostEntity.cs @@ -20,10 +20,10 @@ namespace Timeline.Entities public TimelineEntity Timeline { get; set; } = default!; [Column("author")] - public long AuthorId { get; set; } + public long? AuthorId { get; set; } [ForeignKey(nameof(AuthorId))] - public UserEntity Author { get; set; } = default!; + public UserEntity? Author { get; set; } = default!; [Column("content_type"), Required] public string ContentType { get; set; } = default!; -- cgit v1.2.3