Skip to content

Commit b8d0249

Browse files
juliusknorrrullzer
authored andcommitted
Fix log error when creating files from an empty template
Signed-off-by: Julius Härtl <jus@bitgrid.net>
1 parent 83330b8 commit b8d0249

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

lib/private/Files/Template/TemplateManager.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,7 @@ public function createFromTemplate(string $filePath, string $templateId = '', st
159159
}
160160
$folder = $userFolder->get(dirname($filePath));
161161
$targetFile = $folder->newFile(basename($filePath));
162+
$template = null;
162163
if ($templateType === 'user' && $templateId !== '') {
163164
$template = $userFolder->get($templateId);
164165
$template->copy($targetFile->getPath());

0 commit comments

Comments
 (0)