From 4ef43da23b795d39f9f9b7fd9a1b54c9e1950d41 Mon Sep 17 00:00:00 2001 From: NewKind Date: Thu, 14 May 2020 08:28:34 +0200 Subject: [PATCH] Fix for removing false and 0 values from array --- opensrs/openSRS_loader.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/opensrs/openSRS_loader.php b/opensrs/openSRS_loader.php index 83ffa6e8..42643a4d 100644 --- a/opensrs/openSRS_loader.php +++ b/opensrs/openSRS_loader.php @@ -89,5 +89,9 @@ function array_filter_recursive($input) } } - return array_filter($input); + return array_filter($input, 'is_not_null'); +} + +function is_not_null($value) { + return !is_null($value); }