Skip to content

Commit 65324c7

Browse files
committed
Improving signal to noise ratio on error
1 parent e1dec43 commit 65324c7

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/PatternLab/PatternEngine/Twig/Loaders/PatternLoader.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,8 @@ public function render($options = array()) {
122122
// outputs the raw Twig file contents like `@atoms/buttons/button.twig`.
123123
// @todo Remove this once `Twig_Loader_String` is removed.
124124
if (strpos($result, "@") === 0) {
125-
throw new \Twig_Error_Loader("Twig file not found: " . $result . "\n");
125+
echo "Twig file not found: " . $result . "\n";
126+
exit(1);
126127
} else {
127128
return $result;
128129
}

0 commit comments

Comments
 (0)