canton7 / fuelphp-casset

Better asset management library for fuelphp (with minification!)
MIT License
103 stars 29 forks source link

When a non combined group is rendered, every files are included #3

Closed krtek4 closed 13 years ago

krtek4 commented 13 years ago

When multiple css groups are defined and one of them is set as non-combined, Casset will render the files from every group when rendering this precise group.

For example, if you have : 'css' => array( 'group1' => array( 'files' => array('file1', 'file2'), 'combine' => false, ), 'group2' => array( 'files' => array('file3' ), 'group3' => array( 'files' => array('file4' ), ),

file3 and file4 will be renderd two times, once in a combined form and once with the files from group1.

I think, the problem is caused by an unwanted foreach loop on the line 551 of casset.php. Removing this line solved the problem for me.

canton7 commented 13 years ago

Looks like you're completely correct -- I had to pull that foreach loop out of the if...else for a change a little back, and looks like I missed that one, apologies!

I'll get it it fixed later tonight when I'm near a computer with git on.