Terrific module :) It was working great in initial config, but on Drupal 8.8.1 / PHP 7.3.8 I encountered the following wsod error after importing config and image managed by this module and viewing an entity that displays a field with a formatter provided by this module:
Error: Using $this when not in object context in Drupal\Core\File\FileSystem::dirname() (line 148 of core/lib/Drupal/Core/File/FileSystem.php).
...
and another message not shown except in watchdog or next renderable screen:
Deprecated function: Non-static method Drupal\Core\File\FileSystem::uriScheme() should not be called statically in Drupal\config_default_image\Plugin\Field\FieldFormatter\ConfigDefaultImageFormatter->viewElements() (line 187 of modules/contrib/config_default_image/src/Plugin/Field/FieldFormatter/ConfigDefaultImageFormatter.php).
Drupal\config_default_image\Plugin\Field\FieldFormatter\ConfigDefaultImageFormatter->viewElements(Object, 'en') (Line: 89)
Drupal\Core\Field\FormatterBase->view(Object, 'en') (Line: 76)
...
The error will not show if the derived image style was already created one time in the sites/default/files/config_default_image folder. With the forthcoming patch, the error won't happen either :)
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | config_default_image-wsod-non-static-method-and-deprecated-warning-3105770-1.patch | 3.1 KB | texas-bronius |
Comments
Comment #2
texas-bronius commentedComment #5
gaëlgThank you very much! This has been committed to both branches.