private function loadAssets()
{
if ($this->loadedAssets) {
return;
}
foreach ((array) $this->registerAssets() as $asset) {
if (!$asset instanceof AssetInterface) {
throw new \InvalidArgumentException(sprintf('%s::registerAssets() should return a list of Bolt\\Asset\\AssetInterface objects. Got: %s', get_called_class(), is_object($asset) ? get_class($asset) : gettype($asset)));
}
$this->addAsset($asset);
}
$this->loadedAssets = true;
}