- Added a Picea's reference into templates. This allows extensions to call themselves after compilation.
This commit is contained in:
1 parent
423d74aa6c
commit
a56b64cf49
3 files changed
+79
-28
No files matched your search
@@ -97,4 +97,15 @@ class Compiler
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function getExtensionFromToken(string $name) : Extension\Extension
|
||||
{
|
||||
if ( false === $this->extensionList[$name] ?? false ) {
|
||||
throw new \InvalidArgumentException(<<<MSG
|
||||
Requested extension from token `$name` could not be found from loaded Picea compiler's extension.
|
||||
MSG);
|
||||
}
|
||||
|
||||
return $this->extensionList[$name];
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user