core icon indicating copy to clipboard operation
core copied to clipboard

Image(_Driver) class does not run closures in config.

Open Altreus opened this issue 12 years ago • 1 comments

Image_Driver stores a config that is the top-level image config merged with the config array passed in. This means that \Config::get is never used on the actual config values themselves.

I added a \Fuel::value in the instance where this was causing me a problem but I wasn't sure whether it was best to do this in all instances of $this->config or to change the way the config was accessed in the first place.

Altreus avatar Aug 23 '13 13:08 Altreus

I think this isn't the only place where config is copied to an internal structure, so you might encounter this issue elsewhere as well.

Quickest solution is to use Fuel::value() in the config file itself, or assign the closure and call it in the assignment. But that probably won't work if your closure requires runtime data...

WanWizard avatar Aug 23 '13 15:08 WanWizard