summaryrefslogtreecommitdiffstats
path: root/ms/controllerblueprints/modules/service/src
diff options
context:
space:
mode:
Diffstat (limited to 'ms/controllerblueprints/modules/service/src')
-rw-r--r--ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt11
1 files changed, 5 insertions, 6 deletions
diff --git a/ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt b/ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt
index df8cffdba..e339bcd68 100644
--- a/ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt
+++ b/ms/controllerblueprints/modules/service/src/main/kotlin/org/onap/ccsdk/cds/controllerblueprints/service/handler/ResourceDictionaryHandler.kt
@@ -21,7 +21,7 @@ import com.google.common.base.Preconditions
import org.apache.commons.collections.CollectionUtils
import org.apache.commons.lang3.StringUtils
import org.onap.ccsdk.cds.controllerblueprints.core.BluePrintException
-import org.onap.ccsdk.cds.controllerblueprints.core.checkNotEmptyOrThrow
+import org.onap.ccsdk.cds.controllerblueprints.core.checkNotEmpty
import org.onap.ccsdk.cds.controllerblueprints.resource.dict.ResourceSourceMapping
import org.onap.ccsdk.cds.controllerblueprints.resource.dict.factory.ResourceSourceMappingFactory
import org.onap.ccsdk.cds.controllerblueprints.service.domain.ResourceDictionary
@@ -137,12 +137,11 @@ class ResourceDictionaryHandler(private val resourceDictionaryRepository: Resour
}
private fun validateResourceDictionary(resourceDictionary: ResourceDictionary): Boolean {
- checkNotEmptyOrThrow(resourceDictionary.name, "DataDictionary Definition name is missing.")
+ checkNotEmpty(resourceDictionary.name){ "DataDictionary Definition name is missing."}
checkNotNull(resourceDictionary.definition) { "DataDictionary Definition Information is missing." }
- checkNotEmptyOrThrow(resourceDictionary.description, "DataDictionary Definition Information is missing.")
- checkNotEmptyOrThrow(resourceDictionary.tags, "DataDictionary Definition tags is missing.")
- checkNotEmptyOrThrow(resourceDictionary.updatedBy, "DataDictionary Definition updatedBy is missing.")
+ checkNotEmpty(resourceDictionary.description){ "DataDictionary Definition Information is missing."}
+ checkNotEmpty(resourceDictionary.tags){ "DataDictionary Definition tags is missing."}
+ checkNotEmpty(resourceDictionary.updatedBy){ "DataDictionary Definition updatedBy is missing."}
return true
-
}
} \ No newline at end of file