UnionOfRAD/lithium — Issue #306: Configurations are overriden rather than merged in lithium\core\Adaptable::config()
Author: rich97
Created: 2012-01-31 11:50:42+00:00
State: open

`Line 76:`
if ($config && is_array($config)) {
static::$_configurations = $config;
return;
}

This may be intended behaviour but I don't think it should be this way. If I have one configuration of an adaptable class in my main `app/config` directory and I decide I want to add another configuration of the same class in my `app/libraries/plugin/config` so that I may redistribute it with that configuration then one of those configurations will get overridden (depending on how you have configured the application.)

IMO it should be equivalent to:

static::$_configurations = array_merge(static::$_configurations, $config);

and the configuration should only be removed if you explicitly unset it.