feat: fix syntax error

This commit is contained in:
Joel Male
2024-03-28 12:51:03 +10:00
parent 3af123dc1e
commit a976623266
4 changed files with 11 additions and 7 deletions
+4 -2
View File
@@ -27,10 +27,12 @@ async function run() {
? process.env.insecure == 'true'
: false
const githubEvent = core.getInput('github_event') == 'true'
// if github_event is set to true, append it to the body
if (process.env.github_event && body) {
if (githubEvent) {
// decode the body
const decodedBody = JSON.parse(body)
const decodedBody = JSON.parse(body || '{}')
// set the github event
decodedBody.github_event = context