This commit is contained in:
parent
0d176c7aff
commit
9d174f8ef4
2 changed files with 3 additions and 10 deletions
|
@ -15,8 +15,7 @@ public class UserRenderer(
|
||||||
IOptions<Config.InstanceSection> config,
|
IOptions<Config.InstanceSection> config,
|
||||||
IOptionsSnapshot<Config.SecuritySection> security,
|
IOptionsSnapshot<Config.SecuritySection> security,
|
||||||
MfmConverter mfmConverter,
|
MfmConverter mfmConverter,
|
||||||
DatabaseContext db,
|
DatabaseContext db
|
||||||
FlagService flags
|
|
||||||
) : IScopedService
|
) : IScopedService
|
||||||
{
|
{
|
||||||
private readonly string _transparent = $"https://{config.Value.WebDomain}/assets/transparent.png";
|
private readonly string _transparent = $"https://{config.Value.WebDomain}/assets/transparent.png";
|
||||||
|
@ -77,13 +76,7 @@ public class UserRenderer(
|
||||||
IsBot = user.IsBot,
|
IsBot = user.IsBot,
|
||||||
IsDiscoverable = user.IsExplorable,
|
IsDiscoverable = user.IsExplorable,
|
||||||
Fields = fields?.ToList() ?? [],
|
Fields = fields?.ToList() ?? [],
|
||||||
Emoji = profileEmoji,
|
Emoji = profileEmoji
|
||||||
Pleroma = flags?.IsPleroma.Value == true
|
|
||||||
? new PleromaUserExtensions
|
|
||||||
{
|
|
||||||
IsAdmin = user.IsAdmin,
|
|
||||||
IsModerator = user.IsModerator
|
|
||||||
} : null
|
|
||||||
};
|
};
|
||||||
|
|
||||||
if (localUser is null && security.Value.PublicPreview == Enums.PublicPreview.RestrictedNoMedia) //TODO
|
if (localUser is null && security.Value.PublicPreview == Enums.PublicPreview.RestrictedNoMedia) //TODO
|
||||||
|
|
|
@ -30,7 +30,7 @@ public class AccountEntity : IIdentifiable
|
||||||
[J("emojis")] public required List<EmojiEntity> Emoji { get; set; }
|
[J("emojis")] public required List<EmojiEntity> Emoji { get; set; }
|
||||||
[J("id")] public required string Id { get; set; }
|
[J("id")] public required string Id { get; set; }
|
||||||
[J("last_status_at")] public string? LastStatusAt { get; set; }
|
[J("last_status_at")] public string? LastStatusAt { get; set; }
|
||||||
[J("pleroma")] public required PleromaUserExtensions? Pleroma { get; set; }
|
//[J("pleroma")] public required PleromaUserExtensions? Pleroma { get; set; }
|
||||||
|
|
||||||
[J("avatar_description")] public required string AvatarDescription { get; set; }
|
[J("avatar_description")] public required string AvatarDescription { get; set; }
|
||||||
[J("header_description")] public required string HeaderDescription { get; set; }
|
[J("header_description")] public required string HeaderDescription { get; set; }
|
||||||
|
|
Loading…
Add table
Reference in a new issue