mirror of
https://github.com/FOSSBilling/FOSSBilling.git
synced 2026-12-04 14:13:52 +09:00
Restore correct JSON and array handling for Servicelicense (#2919)
* Restore correct JSON and array handling * Update src/modules/Servicelicense/Server.php Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
1 parent
48bb35386d
commit
c2dcd13759
1 file changed
+1
-1
@@ -69,7 +69,7 @@ class Server implements \FOSSBilling\InjectionAwareInterface
|
||||
|
||||
public function process($data)
|
||||
{
|
||||
$data = (!is_array($data)) ? json_decode($data ?? '', true) : [];
|
||||
$data = is_array($data) ? $data : (json_decode($data ?? '', true) ?: []);
|
||||
|
||||
if (empty($data)) {
|
||||
throw new \LogicException('Invalid request. Parameters missing?', 1000);
|
||||
|
||||
Reference in new issue
Block a user