fix: [document] document.data null 참조 오류 수정

- DocumentController: resolveAndBackfillBasicFields에서 data null-safe 처리
- show.blade.php: $docData 변수로 일괄 치환 (클로저 포함 전체 12곳)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-04 23:30:41 +09:00
parent 491426fc3e
commit fd017a9e34
2 changed files with 19 additions and 18 deletions

View File

@@ -290,7 +290,7 @@ private function resolveAndBackfillBasicFields(Document $document): void
}
// bf_ 레코드가 하나라도 있으면 이미 저장된 것 → skip
$existingBfCount = $document->data
$existingBfCount = ($document->data ?? collect())
->filter(fn ($d) => str_starts_with($d->field_key, 'bf_'))
->count();
if ($existingBfCount > 0) {