widmogrod / zf2-assetic-module

Zend Framework module for Assetic
146 stars 62 forks source link

CacheBuster: use AssetFactory::getLastModified($asset) #154

Closed MatthiasKuehneEllerhold closed 8 years ago

MatthiasKuehneEllerhold commented 8 years ago

This is an addendum to PR #153:

Using the asset factories getLastModified($asset) instead of the $asset->getLastModified() method enables that changes in dependent assets will lead to changes in the target file too.

This PR is to fix an oversight from the last PR (#153) where $asset->getLastModified() was replaced with $factory->getLastModified($asset) in the service. As it turns out there are two more occurances:

The change needed for the cache buster was simple enough, but the view helper needs some refactoring to be able to use the correct last-modified-timestamp.

How do you want to proceed for the view helper?

widmogrod commented 8 years ago

Thank you! :)