TypeError: Cannot access offset of type string on string in Drupal\eca_tamper\Plugin\ECA\Condition\Tamper->buildConfigurationForm()
>>> [!note] Migrated issue
<!-- Drupal.org comment -->
<!-- Migrated from issue #3387153. -->
Reported by: [rolandoscott](https://www.drupal.org/user/2945243)
Related to !6
>>>
<h3 id="summary-problem-motivation">Problem/Motivation</h3>
<p>Whenever I try to access any of the tamper filters using the ECA Classic Modeller, i get a WSOD. The full error on the log is:</p>
<blockquote><p>TypeError: Cannot access offset of type string on string in Drupal\eca_tamper\Plugin\ECA\Condition\Tamper->buildConfigurationForm() (line 68 of /app/web/modules/contrib/eca_tamper/src/Plugin/ECA/Condition/Tamper.php)</p>
<p>#0 /app/web/modules/contrib/eca_cm/src/Form/EcaPluginForm.php(306): Drupal\eca_tamper\Plugin\ECA\Condition\Tamper->buildConfigurationForm()<br>
#1 [internal function]: Drupal\eca_cm\Form\EcaPluginForm->buildForm()<br>
#2 /app/web/core/lib/Drupal/Core/Form/FormBuilder.php(536): call_user_func_array()<br>
#3 /app/web/core/lib/Drupal/Core/Form/FormBuilder.php(283): Drupal\Core\Form\FormBuilder->retrieveForm()<br>
#4 /app/web/core/lib/Drupal/Core/Form/FormBuilder.php(224): Drupal\Core\Form\FormBuilder->buildForm()<br>
#5 /app/web/modules/contrib/eca_cm/src/Controller/CoreModeller.php(200): Drupal\Core\Form\FormBuilder->getForm()<br>
#6 [internal function]: Drupal\eca_cm\Controller\CoreModeller->addCondition()<br>
#7 /app/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array()<br>
#8 /app/web/core/lib/Drupal/Core/Render/Renderer.php(580): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()<br>
#9 /app/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext()<br>
#10 /app/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext()<br>
#11 /app/vendor/symfony/http-kernel/HttpKernel.php(169): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()<br>
#12 /app/vendor/symfony/http-kernel/HttpKernel.php(81): Symfony\Component\HttpKernel\HttpKernel->handleRaw()<br>
#13 /app/web/core/lib/Drupal/Core/StackMiddleware/Session.php(58): Symfony\Component\HttpKernel\HttpKernel->handle()<br>
#14 /app/web/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(48): Drupal\Core\StackMiddleware\Session->handle()<br>
#15 /app/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(106): Drupal\Core\StackMiddleware\KernelPreHandle->handle()<br>
#16 /app/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(85): Drupal\page_cache\StackMiddleware\PageCache->pass()<br>
#17 /app/web/core/modules/ban/src/BanMiddleware.php(50): Drupal\page_cache\StackMiddleware\PageCache->handle()<br>
#18 /app/web/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(48): Drupal\ban\BanMiddleware->handle()<br>
#19 /app/web/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(51): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle()<br>
#20 /app/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle()<br>
#21 /app/web/core/lib/Drupal/Core/DrupalKernel.php(718): Stack\StackedHttpKernel->handle()<br>
#22 /app/web/index.php(19): Drupal\Core\DrupalKernel->handle()<br>
#23 {main}</p></blockquote>
<h4 id="summary-steps-reproduce">Steps to reproduce</h4>
<p>Drupal Version<br>
9.5.10 </p>
<p>PHP Version<br>
8.1.21</p>
<p>Install ECA and this module<br>
Try to add any tamper action as a Condition.</p>
issue