From 2b6df7e36dcafb3e837ad8c9e95679614dc77ad4 Mon Sep 17 00:00:00 2001 From: Benjamin Dupont Date: Sun, 3 Nov 2019 13:56:08 -0500 Subject: [PATCH] better name for check --- src/blogify/backend/annotations/check.kt | 2 +- src/blogify/backend/resources/slicing/Mapper.kt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/blogify/backend/annotations/check.kt b/src/blogify/backend/annotations/check.kt index bd47e65b..13e281c9 100644 --- a/src/blogify/backend/annotations/check.kt +++ b/src/blogify/backend/annotations/check.kt @@ -7,5 +7,5 @@ import org.intellij.lang.annotations.Language @Retention(AnnotationRetention.RUNTIME) @MustBeDocumented annotation class check ( - @Language(value = "RegExp") val check: String + @Language(value = "RegExp") val pattern: String ) \ No newline at end of file diff --git a/src/blogify/backend/resources/slicing/Mapper.kt b/src/blogify/backend/resources/slicing/Mapper.kt index a71fe224..23c6d735 100644 --- a/src/blogify/backend/resources/slicing/Mapper.kt +++ b/src/blogify/backend/resources/slicing/Mapper.kt @@ -72,7 +72,7 @@ fun KClass.buildPropMap(): PropMap { PropertyHandle.AccessDenied(name) } else { if (self.returnType.findAnnotation() != null) { - val regex = Regex(self.returnType.findAnnotation()!!.check) + val regex = Regex(self.returnType.findAnnotation()!!.pattern) PropertyHandle.Ok(name, regex, self as KProperty1) } else { PropertyHandle.Ok(name, null, self as KProperty1)