fix(blog): fix rss permalink

This commit is contained in:
Oliver Booth 2023-08-20 14:23:50 +01:00
parent 0e583de316
commit ffaa2b2fa4
Signed by: oliverbooth
GPG Key ID: B89D139977693FED
2 changed files with 23 additions and 5 deletions

View File

@ -12,16 +12,16 @@ public sealed class BlogItem
[XmlElement("comments")]
public string Comments { get; set; } = default!;
[XmlElement("creator", Namespace = "http://purl.org/dc/elements/1.1/")]
public string Creator { get; set; } = default!;
[XmlElement("pubDate")]
public string PubDate { get; set; } = default!;
[XmlElement("guid")]
public string Guid { get; set; } = default!;
public BlogItemGuid Guid { get; set; } = default!;
[XmlElement("description")]
public string Description { get; set; } = default!;
}

View File

@ -0,0 +1,18 @@
using System.Xml.Serialization;
namespace OliverBooth.Data.Blog.Rss;
public struct BlogItemGuid
{
public BlogItemGuid()
{
}
[XmlAttribute("isPermaLink")]
public bool IsPermaLink { get; set; } = false;
[XmlText]
public string Value { get; set; } = default!;
public static implicit operator BlogItemGuid(string value) => new() { Value = value };
}