Apply suggestions from code review

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This commit is contained in:
usbharu 2023-11-18 13:41:13 +09:00 committed by GitHub
parent 2dd10890da
commit 6fa136d618
3 changed files with 1 additions and 3 deletions

View File

@ -7,7 +7,6 @@ class Nodeinfo {
protected constructor()
}
class Links {
var rel: String? = null
var href: String? = null

View File

@ -31,6 +31,7 @@ data class User private constructor(
class UserBuilder(private val characterLimit: CharacterLimit, private val applicationConfig: ApplicationConfig) {
private val logger = LoggerFactory.getLogger(UserBuilder::class.java)
@Suppress("LongParameterList", "FunctionMinLength", "LongMethod")
fun of(
id: Long,

View File

@ -19,7 +19,6 @@ interface InstanceService {
suspend fun createNewInstance(instanceCreateDto: InstanceCreateDto): Instance
}
@Service
class InstanceServiceImpl(
private val instanceRepository: InstanceRepository,
@ -42,7 +41,6 @@ class InstanceServiceImpl(
val nodeinfo = objectMapper.readValue(nodeinfoJson, Nodeinfo::class.java)
val nodeinfoPathMap = nodeinfo.links.associate { it.rel to it.href }
for ((key, value) in nodeinfoPathMap) {
when (key) {
"http://nodeinfo.diaspora.software/ns/schema/2.0" -> {