Skip to content

Instantly share code, notes, and snippets.

@szeidler
Created March 9, 2018 06:17
Show Gist options
  • Save szeidler/3f099951d6782876a3050510af1caae4 to your computer and use it in GitHub Desktop.
Save szeidler/3f099951d6782876a3050510af1caae4 to your computer and use it in GitHub Desktop.
Adds core compatibility for file_entity and Drupal 8.5.0
diff --git a/src/Plugin/Field/FieldFormatter/FileImageFormatter.php b/src/Plugin/Field/FieldFormatter/FileImageFormatter.php
index 8b06009..1f719f2 100644
--- a/src/Plugin/Field/FieldFormatter/FileImageFormatter.php
+++ b/src/Plugin/Field/FieldFormatter/FileImageFormatter.php
@@ -20,7 +20,7 @@ use Symfony\Component\DependencyInjection\ContainerInterface;
* id = "file_image",
* label = @Translation("File Image"),
* field_types = {
- * "uri"
+ * "file_uri"
* }
* )
*/
diff --git a/src/Plugin/Field/FieldFormatter/FileImageResponsiveFormatter.php b/src/Plugin/Field/FieldFormatter/FileImageResponsiveFormatter.php
index f8c41bd..335e5a3 100644
--- a/src/Plugin/Field/FieldFormatter/FileImageResponsiveFormatter.php
+++ b/src/Plugin/Field/FieldFormatter/FileImageResponsiveFormatter.php
@@ -20,7 +20,7 @@ use Drupal\Core\Utility\LinkGeneratorInterface;
* id = "file_image_responsive",
* label = @Translation("Responsive image"),
* field_types = {
- * "uri",
+ * "file_uri",
* }
* )
*/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment