From e08d0c00f4e1a1c063a5876f856902bb47de154c Mon Sep 17 00:00:00 2001 From: "@ChristelLoftus" <christel@bob.co.za> Date: Wed, 2 Apr 2025 11:58:31 +0200 Subject: [PATCH] #19 - prevent null values for allowed methods --- Model/Carrier/BobGo.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Model/Carrier/BobGo.php b/Model/Carrier/BobGo.php index d269be1..938e847 100644 --- a/Model/Carrier/BobGo.php +++ b/Model/Carrier/BobGo.php @@ -535,7 +535,7 @@ class BobGo extends AbstractCarrierOnline implements \Magento\Shipping\Model\Car public function getAllowedMethods(): array { $allowedMethods = $this->getConfigData('allowed_methods'); - if ($allowedMethods === false) { + if ($allowedMethods === false || $allowedMethods === null || trim($allowedMethods) === '') { return []; // Return an empty array if no allowed methods are configured } -- GitLab