Skip to content
Snippets Groups Projects
Commit 239758b4 authored by Daniel Cothran's avatar Daniel Cothran Committed by Daniel Cothran
Browse files

Issue #3263413 by andileco, hmdnawaz, crutch, nikathone: Warning: Undefined...

Issue #3263413 by andileco, hmdnawaz, crutch, nikathone: Warning: Undefined array key "library" in Drupal\charts\Element\BaseSettings::processSettings()...line 125...\BaseSettings.php
parent ae0289b1
No related branches found
No related tags found
No related merge requests found
......@@ -288,7 +288,8 @@ class Chart extends RenderElement implements ContainerFactoryPluginInterface {
$definitions = $this->chartsManager->getDefinitions();
if (!$library || $library === 'site_default') {
$charts_settings = $this->configFactory->get('charts.settings');
$library = $charts_settings->get('charts_default_settings.library') ?? key($definitions);
$default_settings_library = $charts_settings->get('charts_default_settings.library');
$library = !empty($default_settings_library) ? $default_settings_library : key($definitions);
}
elseif (!isset($definitions[$library])) {
$library = key($definitions);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment