-
Notifications
You must be signed in to change notification settings - Fork 90
Description
Describe the bug
Getting NPE on custom script creation
To Reproduce
Steps to reproduce the behavior:
- Create script.json with details. Do not specify loctionType field
- See error
{
"cause1":"java.lang.NullPointerException: Cannot invoke
"io.jans.model.ScriptLocationType.getValue()" because the return value of
"io.jans.model.custom.script.model.CustomScript.getLocationType()" is null",
"servlet":"io.jans.configapi.rest.ApiApplication",
"cause0":"org.jboss.resteasy.spi.UnhandledException:
java.lang.NullPointerException: Cannot invoke
"io.jans.model.ScriptLocationType.getValue()" because the return value of
"io.jans.model.custom.script.model.CustomScript.getLocationType()" is null",
"message":"org.jboss.resteasy.spi.UnhandledException:
java.lang.NullPointerException: Cannot invoke
"io.jans.model.ScriptLocationType.getValue()" because the return value of
"io.jans.model.custom.script.model.CustomScript.getLocationType()" is null",
"url":"/jans-config-api/api/v1/config/scripts",
"status":"500"
}
Expected behavior
Create Script should get created without error
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
- OS: [e.g. iOS]
- Browser [e.g. chrome, safari]
- Version [e.g. 22]
Smartphone (please complete the following information):
- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- Browser [e.g. stock browser, safari]
- Version [e.g. 22]
Additional context
Add any other context about the problem here.