PHP errors caused by media library popup

Created on 1 February 2023, almost 2 years ago
Updated 6 February 2023, almost 2 years ago

On a clean 9.5 install with the 1.0.x-dev module. Every time I use the media library, either directly on a field, or with the WYSIWYG button, I get these PHP errors.

Warning: foreach() argument must be of type array|object, null given in Drupal\acquia_dam\AssetLibraryBuilder->addSourceMenu() (line 509 of /var/www/web/modules/contrib/acquia_dam/src/AssetLibraryBuilder.php)
#0 /var/www/web/core/includes/bootstrap.inc(347): _drupal_error_handler_real(2, 'foreach() argum...', '/var/www/web/mo...', 509)
#1 /var/www/web/modules/contrib/acquia_dam/src/AssetLibraryBuilder.php(509): _drupal_error_handler(2, 'foreach() argum...', '/var/www/web/mo...', 509)
#2 /var/www/web/modules/contrib/acquia_dam/src/AssetLibraryBuilder.php(422): Drupal\acquia_dam\AssetLibraryBuilder->addSourceMenu(Object(Drupal\media_library\MediaLibraryState), 'core')
#3 [internal function]: Drupal\acquia_dam\AssetLibraryBuilder->buildUi(Object(Drupal\media_library\MediaLibraryState))
#4 /var/www/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array(Array, Array)
...
Warning: Undefined array key "#links" in Drupal\acquia_dam\AssetLibraryBuilder->addSourceMenu() (line 509 of /var/www/web/modules/contrib/acquia_dam/src/AssetLibraryBuilder.php)
#0 /var/www/web/core/includes/bootstrap.inc(347): _drupal_error_handler_real(2, 'Undefined array...', '/var/www/web/mo...', 509)
#1 /var/www/web/modules/contrib/acquia_dam/src/AssetLibraryBuilder.php(509): _drupal_error_handler(2, 'Undefined array...', '/var/www/web/mo...', 509)
#2 /var/www/web/modules/contrib/acquia_dam/src/AssetLibraryBuilder.php(422): Drupal\acquia_dam\AssetLibraryBuilder->addSourceMenu(Object(Drupal\media_library\MediaLibraryState), 'core')
#3 [internal function]: Drupal\acquia_dam\AssetLibraryBuilder->buildUi(Object(Drupal\media_library\MediaLibraryState))
#4 /var/www/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array(Array, Array)
...
πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States davidhernandez USA

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024