From d5a7b58c488b32d17ade64782e0ebb140ff5b1c0 Mon Sep 17 00:00:00 2001 From: Christy Jacob Date: Thu, 24 Jun 2021 01:52:43 +0530 Subject: [PATCH] feat: pass empty string instead of null in functions worker --- app/workers/functions.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/workers/functions.php b/app/workers/functions.php index 5299970e5..ffc786a62 100644 --- a/app/workers/functions.php +++ b/app/workers/functions.php @@ -145,6 +145,7 @@ class FunctionsV1 extends Worker $event = $this->args['event'] ?? ''; $scheduleOriginal = $this->args['scheduleOriginal'] ?? ''; $eventData = (!empty($this->args['eventData'])) ? json_encode($this->args['eventData']) : ''; + var_dump($eventData); $data = $this->args['data'] ?? ''; $userId = $this->args['userId'] ?? ''; $jwt = $this->args['jwt'] ?? ''; @@ -353,7 +354,7 @@ class FunctionsV1 extends Worker \array_walk($vars, function (&$value, $key) { $key = $this->filterEnvKey($key); - $value = \escapeshellarg((empty($value)) ? 'null' : $value); + $value = \escapeshellarg((empty($value)) ? '' : $value); $value = "--env {$key}={$value}"; });