Skip to content

Commit 421d95b

Browse files
committed
fix: only use file when exists
Signed-off-by: Vitor Mattos <[email protected]>
1 parent 99c239a commit 421d95b

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

lib/Service/FileService.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,8 +299,7 @@ public function isLibresignFile(int $nodeId): bool {
299299

300300
private function loadFileMetadata(): void {
301301
if (
302-
!$this->file
303-
|| $this->file->getNodeType() !== 'file'
302+
($this->file instanceof File && $this->file->getNodeType() !== 'file')
304303
|| !$content = $this->getFileContent()
305304
) {
306305
return;

0 commit comments

Comments
 (0)