This is a quick follow-up to #2639526: Calling BlockDisplayVariant::setConfiguration() won't change results returned from plugin collections
The code that was committed works great if your calling BlockDisplayVariant::setConfiguration($config)
with a config array that you got from calling BlockDisplayVariant::getConfiguartion()
- however, it's actually quite common to call setConfiguration([])
when creating a new variant! In that case, there are some (harmless) PHP warnings.
Basically, we need to use the configuration after the defaults are mixed in to prevent these warnings. I'll attach a patch in a moment.
Comment | File | Size | Author |
---|---|---|---|
#5 | ctools-block-display-warnings-2639926-5.patch | 4.85 KB | dsnopek |
Comments
Comment #2
dsnopekHere's the patch!
Comment #5
dsnopekBah! I think that was actually a problem with the test: it depended on the container (which isn't initialized in a unit test), rather than injecting its dependencies. This one runs for me locally!
Comment #6
EclipseGc CreditAttribution: EclipseGc at Acquia commentedlooks good!
fixed
Eclipse