diff --git a/lib/Controller/AttachmentApiController.php b/lib/Controller/AttachmentApiController.php index d8a35db59..b50e7d9f9 100644 --- a/lib/Controller/AttachmentApiController.php +++ b/lib/Controller/AttachmentApiController.php @@ -48,7 +48,7 @@ public function display(int $cardId, int $attachmentId, string $type = 'deck_fil #[CORS] #[NoCSRFRequired] public function create(int $cardId, string $type, ?string $data): DataResponse { - $attachment = $this->attachmentService->create($cardId, $type, $data); + $attachment = $this->attachmentService->create($cardId, $type, $data ?? ''); return new DataResponse($attachment, HTTP::STATUS_OK); }