Fix exporting
This commit is contained in:
parent
acadad2a43
commit
5d63181cac
@ -14,8 +14,8 @@ namespace PluralKit
|
|||||||
public ProxyTag(string prefix, string suffix)
|
public ProxyTag(string prefix, string suffix)
|
||||||
{
|
{
|
||||||
// Normalize empty strings to null for DB
|
// Normalize empty strings to null for DB
|
||||||
Prefix = prefix.Length == 0 ? null : prefix;
|
Prefix = prefix?.Length == 0 ? null : prefix;
|
||||||
Suffix = suffix.Length == 0 ? null : suffix;
|
Suffix = suffix?.Length == 0 ? null : suffix;
|
||||||
}
|
}
|
||||||
|
|
||||||
[JsonProperty("prefix")] public string Prefix { get; set; }
|
[JsonProperty("prefix")] public string Prefix { get; set; }
|
||||||
@ -72,13 +72,13 @@ namespace PluralKit
|
|||||||
// Don't use, unless you're the API's serialization library
|
// Don't use, unless you're the API's serialization library
|
||||||
[JsonProperty("prefix")] [Obsolete("Use PKMember.ProxyTags")] public string Prefix
|
[JsonProperty("prefix")] [Obsolete("Use PKMember.ProxyTags")] public string Prefix
|
||||||
{
|
{
|
||||||
get => ProxyTags.FirstOrDefault().Prefix;
|
get => ProxyTags?.FirstOrDefault().Prefix;
|
||||||
set => ProxyTags = new[] {new ProxyTag(Prefix, value)};
|
set => ProxyTags = new[] {new ProxyTag(Prefix, value)};
|
||||||
}
|
}
|
||||||
|
|
||||||
[JsonProperty("suffix")] [Obsolete("Use PKMember.ProxyTags")] public string Suffix
|
[JsonProperty("suffix")] [Obsolete("Use PKMember.ProxyTags")] public string Suffix
|
||||||
{
|
{
|
||||||
get => ProxyTags.FirstOrDefault().Prefix;
|
get => ProxyTags?.FirstOrDefault().Prefix;
|
||||||
set => ProxyTags = new[] {new ProxyTag(Prefix, value)};
|
set => ProxyTags = new[] {new ProxyTag(Prefix, value)};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user