Skip to content
This repository was archived by the owner on Jan 20, 2023. It is now read-only.

Commit f2ad0e0

Browse files
committed
ちゃんとクラスが取れていなかったため修正
1 parent 4957332 commit f2ad0e0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/main/kotlin/com/mapk/krowmapper/ParameterForMap.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package com.mapk.krowmapper
22

33
import com.mapk.annotations.KPropertyAlias
4+
import kotlin.reflect.KClass
45
import kotlin.reflect.KParameter
56
import kotlin.reflect.full.findAnnotation
67

@@ -12,7 +13,7 @@ class ParameterForMap<T : Any> private constructor(
1213
companion object {
1314
fun newInstance(param: KParameter, propertyNameConverter: (String) -> String = { it }): ParameterForMap<*> {
1415
val name: String = (param.findAnnotation<KPropertyAlias>()?.value ?: propertyNameConverter(param.name!!))
15-
return ParameterForMap(name, param.index, param.type.javaClass)
16+
return ParameterForMap(name, param.index, (param.type.classifier as KClass<*>).java)
1617
}
1718
}
1819
}

0 commit comments

Comments
 (0)