UP
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
using System;
|
||||
using MongoDB.Bson;
|
||||
using MongoDB.Bson.Serialization.Attributes;
|
||||
|
||||
@@ -7,7 +8,7 @@ namespace StellaOps.Feedser.Storage.Mongo.Documents;
|
||||
public sealed class DocumentDocument
|
||||
{
|
||||
[BsonId]
|
||||
public Guid Id { get; set; }
|
||||
public string Id { get; set; } = string.Empty;
|
||||
|
||||
[BsonElement("sourceName")]
|
||||
public string SourceName { get; set; } = string.Empty;
|
||||
@@ -59,7 +60,7 @@ internal static class DocumentDocumentExtensions
|
||||
{
|
||||
return new DocumentDocument
|
||||
{
|
||||
Id = record.Id,
|
||||
Id = record.Id.ToString(),
|
||||
SourceName = record.SourceName,
|
||||
Uri = record.Uri,
|
||||
FetchedAt = record.FetchedAt.UtcDateTime,
|
||||
@@ -96,7 +97,7 @@ internal static class DocumentDocumentExtensions
|
||||
}
|
||||
|
||||
return new DocumentRecord(
|
||||
document.Id,
|
||||
Guid.Parse(document.Id),
|
||||
document.SourceName,
|
||||
document.Uri,
|
||||
DateTime.SpecifyKind(document.FetchedAt, DateTimeKind.Utc),
|
||||
|
||||
Reference in New Issue
Block a user