Details
-
Bug
-
Status: Done
-
Critical
-
Resolution: Fixed
-
5.5.6
-
None
-
Sprint 54
-
15.7
Description
Users who try to click the "Preview" button when developing their Post Functions will get the following error in the browser console logs and the preview does not work.
Removed some of the error for brevity
Uncaught TypeError: Cannot read property 'toLowerCase' of null at Object.previewBuiltin (com.onresolve.jira.groovy.groovyrunner:combinedAdminSection.js:4) at handlePreview ......
And for the "Send a custom email" post functions that are already present, if the user clicks the Update button they will get as 500 error in the browser console log:
POST http://localhost:8080/rest/scriptrunner/latest/canned/com.onresolve.scriptrunner.canned.jira.workflow.postfunctions.SendCustomEmail/validate 500 POST "http://localhost:8080/rest/scriptrunner/latest/canned/com.onresolve.scriptrunner.canned.jira.workflow.postfunctions.SendCustomEmail/validate".
The 500 error also produces this response JSON:
{"errorMessages":[],"flushedErrorMessages":[],"scriptRunResult":null,"errors":{"events":"You must provide at least one event."}}
Steps to reproduce:
1- Create a Post function
2- Try to preview
3- Create a "Send a custom email" post function and save it
4- Publish the workflow
5- Try to then edit the "Send a custom email" Post function