diff --git a/src/Appwrite/Platform/Workers/Usage.php b/src/Appwrite/Platform/Workers/Usage.php index cdbb7b5aaa..98b2ea32c7 100644 --- a/src/Appwrite/Platform/Workers/Usage.php +++ b/src/Appwrite/Platform/Workers/Usage.php @@ -59,7 +59,13 @@ class Usage extends Action throw new Exception('Missing payload'); } - $project = new Document($payload['project'] ?? []); + $document = $payload['project'] ?? []; + + if (empty($document)) { + var_dump($payload); + } + + $project = new Document($document); $projectId = $project->getInternalId(); foreach ($payload['reduce'] ?? [] as $document) { if (empty($document)) {