fix: name is nullable, preferredUsername is not
This commit is contained in:
parent
7f66851136
commit
f29d3baeb9
2 changed files with 5 additions and 2 deletions
|
@ -18,11 +18,11 @@ impl MigrationTrait for Migration {
|
||||||
)
|
)
|
||||||
.col(ColumnDef::new(Users::ActorType).string().not_null())
|
.col(ColumnDef::new(Users::ActorType).string().not_null())
|
||||||
.col(ColumnDef::new(Users::Domain).string().not_null())
|
.col(ColumnDef::new(Users::Domain).string().not_null())
|
||||||
.col(ColumnDef::new(Users::Name).string().not_null())
|
.col(ColumnDef::new(Users::Name).string().null())
|
||||||
.col(ColumnDef::new(Users::Summary).string().null())
|
.col(ColumnDef::new(Users::Summary).string().null())
|
||||||
.col(ColumnDef::new(Users::Image).string().null())
|
.col(ColumnDef::new(Users::Image).string().null())
|
||||||
.col(ColumnDef::new(Users::Icon).string().null())
|
.col(ColumnDef::new(Users::Icon).string().null())
|
||||||
.col(ColumnDef::new(Users::PreferredUsername).string().null())
|
.col(ColumnDef::new(Users::PreferredUsername).string().not_null())
|
||||||
.col(ColumnDef::new(Users::Inbox).string().null())
|
.col(ColumnDef::new(Users::Inbox).string().null())
|
||||||
.col(ColumnDef::new(Users::SharedInbox).string().null())
|
.col(ColumnDef::new(Users::SharedInbox).string().null())
|
||||||
.col(ColumnDef::new(Users::Outbox).string().null())
|
.col(ColumnDef::new(Users::Outbox).string().null())
|
||||||
|
@ -30,6 +30,7 @@ impl MigrationTrait for Migration {
|
||||||
.col(ColumnDef::new(Users::Followers).string().null())
|
.col(ColumnDef::new(Users::Followers).string().null())
|
||||||
.col(ColumnDef::new(Users::FollowingCount).integer().not_null().default(0))
|
.col(ColumnDef::new(Users::FollowingCount).integer().not_null().default(0))
|
||||||
.col(ColumnDef::new(Users::FollowersCount).integer().not_null().default(0))
|
.col(ColumnDef::new(Users::FollowersCount).integer().not_null().default(0))
|
||||||
|
// .col(ColumnDef::new(Users::StatusesCount).integer().not_null().default(0))
|
||||||
.col(ColumnDef::new(Users::PublicKey).string().not_null())
|
.col(ColumnDef::new(Users::PublicKey).string().not_null())
|
||||||
.col(ColumnDef::new(Users::PrivateKey).string().null())
|
.col(ColumnDef::new(Users::PrivateKey).string().null())
|
||||||
.col(ColumnDef::new(Users::Created).date_time().not_null())
|
.col(ColumnDef::new(Users::Created).date_time().not_null())
|
||||||
|
@ -125,6 +126,7 @@ enum Users {
|
||||||
FollowingCount,
|
FollowingCount,
|
||||||
Followers,
|
Followers,
|
||||||
FollowersCount,
|
FollowersCount,
|
||||||
|
// StatusesCount,
|
||||||
PublicKey,
|
PublicKey,
|
||||||
PrivateKey,
|
PrivateKey,
|
||||||
Created,
|
Created,
|
||||||
|
|
|
@ -24,6 +24,7 @@ pub struct Model {
|
||||||
|
|
||||||
pub following_count: i64,
|
pub following_count: i64,
|
||||||
pub followers_count: i64,
|
pub followers_count: i64,
|
||||||
|
// pub statuses_count: i64,
|
||||||
|
|
||||||
pub public_key: String,
|
pub public_key: String,
|
||||||
pub private_key: Option<String>,
|
pub private_key: Option<String>,
|
||||||
|
|
Loading…
Reference in a new issue