diff --git a/src/main/kotlin/dev/usbharu/hideout/query/FollowerQueryServiceImpl.kt b/src/main/kotlin/dev/usbharu/hideout/query/FollowerQueryServiceImpl.kt index ffcb1ccc..e360ed4f 100644 --- a/src/main/kotlin/dev/usbharu/hideout/query/FollowerQueryServiceImpl.kt +++ b/src/main/kotlin/dev/usbharu/hideout/query/FollowerQueryServiceImpl.kt @@ -5,8 +5,10 @@ import dev.usbharu.hideout.repository.Users import dev.usbharu.hideout.repository.UsersFollowers import org.jetbrains.exposed.sql.* import org.jetbrains.exposed.sql.SqlExpressionBuilder.eq +import org.koin.core.annotation.Single import java.time.Instant +@Single class FollowerQueryServiceImpl : FollowerQueryService { override suspend fun findFollowersById(id: Long): List { val followers = Users.alias("FOLLOWERS") diff --git a/src/main/kotlin/dev/usbharu/hideout/service/user/UserService.kt b/src/main/kotlin/dev/usbharu/hideout/service/user/UserService.kt index c2464ca3..b7ff0e3a 100644 --- a/src/main/kotlin/dev/usbharu/hideout/service/user/UserService.kt +++ b/src/main/kotlin/dev/usbharu/hideout/service/user/UserService.kt @@ -19,8 +19,6 @@ class UserService( ) : IUserService { - override suspend fun findByUrls(urls: List): List = userRepository.findByUrls(urls) - override suspend fun usernameAlreadyUse(username: String): Boolean { val findByNameAndDomain = userRepository.findByNameAndDomain(username, Config.configData.domain) return findByNameAndDomain != null @@ -64,8 +62,6 @@ class UserService( return userRepository.save(userEntity) } - override suspend fun findFollowersById(id: Long): List = userRepository.findFollowersById(id) - // TODO APのフォロー処理を作る override suspend fun followRequest(id: Long, followerId: Long): Boolean { val user = userRepository.findById(id) ?: throw UserNotFoundException("$id was not found.")