Skip to content

Commit 7c7617b

Browse files
author
Greg Bowler
authored
Use template directory for loading components
1 parent e964e01 commit 7c7617b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Dom/Document.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -311,13 +311,13 @@ public function tidy() {
311311
* introduced.
312312
*/
313313
public function loadComponents() {
314-
$componentDirectory = Path::get(Path::COMPONENT);
314+
$templateDirectory = Path::get(Path::TEMPLATE);
315315
$xpath = new \DOMXPath($this->domDocument);
316316
$customNodeList = $xpath->query("//*[contains(name(), '-')]");
317317
for($i = 0; $i < $customNodeList->length; $i++) {
318318
$node = $customNodeList->item($i);
319319
$componentHtmlFile = implode("/", [
320-
$componentDirectory,
320+
$templateDirectory,
321321
$node->tagName . ".html",
322322
]);
323323
if(!is_file($componentHtmlFile)) {

0 commit comments

Comments
 (0)