I could not get this very useful module to work with Drupal 8.6.13 but I did get it working after I upgraded core to 8.7. In 8.6.13 I got the following :-

drush en media_directories
 [warning] array_merge(): Argument #2 is not an array media_directories.install:55
 [warning] array_merge(): Argument #2 is not an array media_directories.install:56
 [warning] array_flip(): Can only flip STRING and INTEGER values! EntityStorageBase.php:264
TypeError: Argument 1 passed to Drupal\Core\Config\Entity\ConfigEntityBase::calculatePluginDependencies() must implement interface Drupal\Component\Plugin\PluginInspectionInterface, null given, called in [...]/web/core/modules/views/src/Entity/View.php on line 290 in [...]/web/core/lib/Drupal/Core/Plugin/PluginDependencyTrait.php on line 68 #0 [...]/web/core/modules/views/src/Entity/View.php(290): Drupal\Core\Config\Entity\ConfigEntityBase->calculatePluginDependencies(NULL)

Unless it's going to be made to work with 8.6 perhaps it's advisable to not say "Drupal 8.7 recommended" but "Drupal 8.7 required"...?

Incidentally, on the Drupal 8.7 install I got the following issues :-

drush en media_directories
 [warning] array_flip(): Can only flip STRING and INTEGER values! EntityStorageBase.php:264
 [warning] array_flip(): Can only flip STRING and INTEGER values! EntityStorageBase.php:264
 [warning] array_flip(): Can only flip STRING and INTEGER values! EntityStorageBase.php:264
 [warning] array_flip(): Can only flip STRING and INTEGER values! EntityStorageBase.php:264
 [success] Successfully enabled: media_directories

However, these are obviously just warnings and the module did install and appears to work fine.

Many thanks for all the great work.

Comments

GlossyIbis created an issue. See original summary.

josephdpurcell’s picture

Status: Active » Needs work
StatusFileSize
new374 bytes

I can confirm this module did not install on 8.6. After upgrading to 8.7 it did install.

Maybe adding a composer.json with the core version required will avoid this issue? I see Lightning does this: https://git.drupalcode.org/project/lightning_core/blob/8.x-4.0-beta1/com...

rang501’s picture

Hi!
Thanks for the patch. Although 8.6 is quite obsolete, it is still a good idea to indicate requirements.
I'll close this issue as fixes, warnings, and notices should be in a separate issue.

rang501’s picture

Status: Needs work » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.