Skip to content
Snippets Groups Projects
Commit 89efbd54 authored by Ankit Pathak's avatar Ankit Pathak
Browse files

Adding BC for typedConfigManager and cspell words to ignore.

parent 7032d70f
No related branches found
No related tags found
1 merge request!54Automated Project Update Bot fixes from run 11-188815.
Addok
addok
addresstext
apikey
arcgisonline
azuremaps
banfrance
behaviour
bingmaps
Bpost
bpost
countrycode
davedevelopment
Enpoints
freegeoip
gecoder
Geocdoer
Geocodes
geocodes
Geohash
geohash
geojsonfile
Geonames
geonames
Geophp
geophp
geoplugin
Geopunt
geopunt
googlemaps
gpxfile
graphhopper
hostip
ipinfodb
kmlfile
latlng
latlon
Mapbox
mapbox
mapquest
maptiler
maxmind
mecanism
Nominatim
nominatim
opencage
Opene
Openrouteservice
openrouteservice
openstreetmap
securitychecker
Stiphle
stiphle
Tidi
tomtom
updb
Wallonie
willdurand
\ No newline at end of file
......@@ -2,6 +2,8 @@
namespace Drupal\geocoder\Form;
use Drupal\Core\Config\ConfigFactoryInterface;
use Drupal\Core\Config\TypedConfigManagerInterface;
use Drupal\Core\Form\ConfigFormBase;
use Drupal\Core\Form\FormStateInterface;
use Symfony\Component\DependencyInjection\ContainerInterface;
......@@ -11,13 +13,6 @@ use Symfony\Component\DependencyInjection\ContainerInterface;
*/
class SettingsForm extends ConfigFormBase {
/**
* {@inheritdoc}
*/
public static function create(ContainerInterface $container) {
return parent::create($container);
}
/**
* {@inheritdoc}
*/
......@@ -37,8 +32,15 @@ class SettingsForm extends ConfigFormBase {
*/
public function buildForm(array $form, FormStateInterface $form_state) {
$config = $this->config('geocoder.settings');
$geocoder_config_schema = $this->typedConfigManager->getDefinition('geocoder.settings') + ['mapping' => []];
if (property_exists(ConfigFormBase::class, 'typedConfigManager')) {
$geocoder_config_schema = $this->typedConfigManager->getDefinition('geocoder.settings') + ['mapping' => []];
}
else {
// Handling backward compatiblity before D10.2
// Calling typedConfigManager() of ConfigFormBase class.
$geocoder_config_schema = $this->typedConfigManager();
}
$geocoder_config_schema = $geocoder_config_schema['mapping'];
// Attach Geofield Map Library.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment