mirror of https://github.com/usbharu/Hideout.git
style: スタイルを修正
This commit is contained in:
parent
34333b1a2d
commit
4985af4291
|
@ -10,7 +10,6 @@ open class Person : Object {
|
|||
var publicKey: Key? = null
|
||||
var endpoints: Map<String, String> = emptyMap()
|
||||
|
||||
|
||||
protected constructor() : super()
|
||||
|
||||
@Suppress("LongParameterList")
|
||||
|
@ -66,5 +65,4 @@ open class Person : Object {
|
|||
result = 31 * result + endpoints.hashCode()
|
||||
return result
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -7,7 +7,6 @@ import io.ktor.server.plugins.statuspages.*
|
|||
import io.ktor.server.response.*
|
||||
|
||||
fun Application.configureStatusPages() {
|
||||
|
||||
install(StatusPages) {
|
||||
exception<IllegalArgumentException> { call, cause ->
|
||||
call.respondText(text = "400: $cause", status = HttpStatusCode.BadRequest)
|
||||
|
|
|
@ -137,7 +137,6 @@ class APNoteServiceImpl(
|
|||
targetActor
|
||||
)
|
||||
|
||||
|
||||
val visibility =
|
||||
if (note.to.contains(public) && note.cc.contains(public)) {
|
||||
Visibility.PUBLIC
|
||||
|
|
|
@ -46,7 +46,6 @@ class UserApiServiceImpl(
|
|||
userQueryService.findAll(min(limit ?: 100, 100), offset).map { UserResponse.from(it) }
|
||||
}
|
||||
|
||||
|
||||
override suspend fun findById(id: Long): UserResponse =
|
||||
transaction.transaction { UserResponse.from(userQueryService.findById(id)) }
|
||||
|
||||
|
@ -71,7 +70,6 @@ class UserApiServiceImpl(
|
|||
followerQueryService.findFollowersById(userId).map { UserResponse.from(it) }
|
||||
}
|
||||
|
||||
|
||||
override suspend fun findFollowings(userId: Long): List<UserResponse> = transaction.transaction {
|
||||
followerQueryService.findFollowingById(userId).map { UserResponse.from(it) }
|
||||
}
|
||||
|
@ -86,7 +84,6 @@ class UserApiServiceImpl(
|
|||
.map { UserResponse.from(it) }
|
||||
}
|
||||
|
||||
|
||||
override suspend fun createUser(username: String, password: String): UserResponse {
|
||||
return transaction.transaction {
|
||||
if (userQueryService.existByNameAndDomain(username, Config.configData.domain)) {
|
||||
|
@ -108,7 +105,8 @@ class UserApiServiceImpl(
|
|||
userQueryService.findByNameAndDomain(
|
||||
targetAcct.username,
|
||||
targetAcct.domain ?: Config.configData.domain
|
||||
).id, sourceId
|
||||
).id,
|
||||
sourceId
|
||||
)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
package dev.usbharu.hideout.util
|
||||
|
||||
class CollectionUtil {
|
||||
}
|
||||
class CollectionUtil
|
||||
|
||||
fun <T> Iterable<T>.singleOr(block: (e: RuntimeException) -> Throwable): T {
|
||||
return try {
|
||||
|
|
Loading…
Reference in New Issue