/**
* @throws Enlight_Event_Exception
* @throws Exception
*
* @return JavascriptDefinition[]
*/
private function collectPluginJavascript(Shop\Shop
$shop, Shop\Template
$template) { $collection =
new ArrayCollection();
$definition =
new JavascriptDefinition();
$this->eventManager->
collect( 'Theme_Compiler_Collect_Plugin_Javascript',
$collection,
['shop' =>
$shop, 'template' =>
$template] );
foreach ($collection as $file) { if (!
file_exists($file)) { throw new Exception(sprintf('Some plugin tries to compress a javascript file, but the file %s doesn\'t exist',
$file));
} }