mirror of https://github.com/usbharu/Hideout.git
fix: #214
This commit is contained in:
parent
b3723da219
commit
8a7ff91a95
|
@ -6,9 +6,9 @@ open class Person
|
|||
@Suppress("LongParameterList")
|
||||
constructor(
|
||||
type: List<String> = emptyList(),
|
||||
override val name: String,
|
||||
val name: String?,
|
||||
override val id: String,
|
||||
var preferredUsername: String?,
|
||||
var preferredUsername: String,
|
||||
var summary: String?,
|
||||
var inbox: String,
|
||||
var outbox: String,
|
||||
|
@ -19,7 +19,7 @@ constructor(
|
|||
var followers: String?,
|
||||
var following: String?,
|
||||
val manuallyApprovesFollowers: Boolean? = false
|
||||
) : Object(add(type, "Person")), HasId, HasName {
|
||||
) : Object(add(type, "Person")), HasId {
|
||||
|
||||
@Suppress("CyclomaticComplexMethod", "CognitiveComplexMethod")
|
||||
override fun equals(other: Any?): Boolean {
|
||||
|
|
|
@ -96,7 +96,7 @@ class APUserServiceImpl(
|
|||
name = person.preferredUsername
|
||||
?: throw IllegalActivityPubObjectException("preferredUsername is null"),
|
||||
domain = id.substringAfter("://").substringBefore("/"),
|
||||
screenName = person.name,
|
||||
screenName = person.name ?: person.preferredUsername,
|
||||
description = person.summary.orEmpty(),
|
||||
inbox = person.inbox,
|
||||
outbox = person.outbox,
|
||||
|
|
Loading…
Reference in New Issue