[backend/database] Fix UserProfile.Field jsonb property attributes

This commit is contained in:
Laura Hausmann 2024-04-03 15:17:52 +02:00
parent d0d0d444ab
commit 7efb48a376
No known key found for this signature in database
GPG key ID: D044E84C5BE01605

View file

@ -2,6 +2,7 @@
using System.ComponentModel.DataAnnotations.Schema;
using Microsoft.EntityFrameworkCore;
using NpgsqlTypes;
using J = System.Text.Json.Serialization.JsonPropertyNameAttribute;
namespace Iceshrimp.Backend.Core.Database.Tables;
@ -179,8 +180,8 @@ public class UserProfile
public class Field
{
public required string Name { get; set; }
public required string Value { get; set; }
public bool? IsVerified { get; set; }
[J("name")] public required string Name { get; set; }
[J("value")] public required string Value { get; set; }
[J("verified")] public bool? IsVerified { get; set; }
}
}