ChartsSettingsService.php in Charts 5.0.x
File
src/Services/ChartsSettingsService.php
View source
<?php
namespace Drupal\charts\Services;
use Drupal\Core\Config\ConfigFactoryInterface;
class ChartsSettingsService implements ChartsSettingsServiceInterface {
private $configFactory;
public function __construct(ConfigFactoryInterface $config_factory) {
$this->configFactory = $config_factory;
}
public function getChartsSettings() {
$config = $this->configFactory
->getEditable('charts.settings');
return $config
->get('charts_default_settings');
}
}