Closed (fixed)
Project:
DROWL Paragraphs
Version:
8.x-3.x-dev
Component:
Code
Priority:
Major
Category:
Bug report
Assigned:
Reporter:
Created:
12 Sep 2022 at 11:20 UTC
Updated:
26 Sep 2022 at 13:44 UTC
Jump to comment: Most recent
TypeError: strtr(): Argument #1 ($string) must be of type string, array given in strtr() (Zeile 570 in /vendor/twig/twig/src/Extension/CoreExtension.php)
The issue seems to be caused by this line:
{{ paragraph.field_image_clip_path.value|replace({"clip-path": "shape-outside"}) }}
in
https://git.drupalcode.org/project/drowl_paragraphs/-/blob/8.x-3.x/modul...
looks like
paragraph.field_image_clip_path.value is an array here?
The resulting PHP code is:
// line 22
echo $this->extensions['Drupal\Core\Template\TwigExtension']->escapeFilter($this->env, twig_replace_filter($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["paragraph"] ?? null), "field_image_clip_path", [], "any", false, false, true, 22), "value", [], "any", false, false, true, 22), 22, $this->source), ["clip-path" => "shape-outside"]), "html", null, true);
echo "
dgs customer issue, see internal details.
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
anybodyComment #3
anybodyComment #9
anybodySame issue exists for 4.x
Comment #10
thomas.frobieterStill buggy in 3.x .. I'll create a new issue fork.. and fix 4.x afterwards.
Comment #13
thomas.frobieter4.x is not affected! So the last commit to 3.x should fix this finally.
Comment #15
thomas.frobieter