Skip to content

Commit 0ec0656

Browse files
committed
fix: add fallback for appOverridesFolder config in View
1 parent a5fc034 commit 0ec0656

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

system/View/View.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -202,8 +202,10 @@ public function render(string $view, ?array $options = null, ?bool $saveData = n
202202
$this->renderVars['file'] = $this->viewPath . $this->renderVars['view'];
203203

204204
if (str_contains($this->renderVars['view'], '\\')) {
205-
$overrideFolder = $this->config->appOverridesFolder !== ''
206-
? trim($this->config->appOverridesFolder, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR
205+
$appOverridesFolder = $this->config->appOverridesFolder ?? 'overrides';
206+
207+
$overrideFolder = $appOverridesFolder !== ''
208+
? trim($appOverridesFolder, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR
207209
: '';
208210

209211
$this->renderVars['file'] = $this->viewPath

0 commit comments

Comments
 (0)