Fix for GRAILS-9414

JSON.parse() can return JSONArray or JSONObject. The signature of the
method returns a JSONElement, so I changed to avoid the exception.