Problem/Motivation
Error:
TypeError: Drupal\geolocation\MapFeatureBase::__construct(): Argument #7 ($libraryDiscovery) must be of type Drupal\Core\Asset\LibraryDiscovery, Drupal\Core\Asset\LibraryDiscoveryCollector given.
In this list of files:
/geolocation/modules/geolocation_geometry/src/Plugin/Validation/Constraint/GeometryConstraint.php
/geolocation/modules/geolocation_geometry/src/Plugin/Validation/Constraint/GeometryConstraintValidator.php
/geolocation/modules/geolocation_leaflet/src/Plugin/geolocation/LayerFeature/LeafletMarkerIcon.php
/geolocation/src/LayerFeatureBase.php
/geolocation/src/MapFeatureBase.php
/geolocation/src/Plugin/geolocation/MapFeature/ControlCustomGeocoder.php
/geolocation/src/Plugin/geolocation/MapFeature/ControlTileLayers.php
Core "library.discovery" service is an instance of LibraryDiscoveryCollector, but these classes expects a Library discovery.
Drupal Core: 11.1.0
Geolocation: 4.0.0-alpha7
Steps to reproduce
With the versions above, create a field and enter in display settings of the field.
Proposed resolution
Use LibraryDiscoveryInterface instead of LibraryDiscovery
Patch attached.
Issue fork geolocation-3494936
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
trickfun commentedSame error for me.
Comment #7
kumareshbaksi commentedMade the changes. MR 88, please review.
Comment #8
sleitner commentedWorks for me
Comment #10
christianadamski commentedThanks!