diff --git a/lib/Service/TemplateFieldService.php b/lib/Service/TemplateFieldService.php index 0ee84d4d50..6c6af3475b 100644 --- a/lib/Service/TemplateFieldService.php +++ b/lib/Service/TemplateFieldService.php @@ -77,7 +77,7 @@ public function extractFields(Node|int $file): array { $httpClient = $this->clientService->newClient(); $form = RemoteOptionsService::getDefaultOptions(); - $form['query'] = ['limit' => 'content-control']; + $form['query'] = ['filter' => 'contentcontrol']; $form['multipart'] = [[ 'name' => 'data', 'contents' => $file->getStorage()->fopen($file->getInternalPath(), 'r'), @@ -93,7 +93,7 @@ public function extractFields(Node|int $file): array { $fields = []; foreach ($documentStructure as $index => $attr) { - $fieldType = FieldType::tryFrom($attr['type']) ?? null; + $fieldType = FieldType::tryFrom($attr['type'] ?? '') ?? null; if ($fieldType === null) { continue; }