Issue Bug Closed

#80919Form CE runs into TypeError when a number is used as option key for a finisher

Daniel Goerz 04/20/17, 15:41 updated 10/02/18, 11:01

Description

Reproduce:

Use custom PartialPath for a Finisher, e.g.:

finishers:
  -
    identifier: 'EmailToReceiver'
    options:
      subject: 'My Subject'
      recipientAddress: info@example.com
      recipientName: 'Some Company'
      senderAddress: '{email}'
      senderName: '{name}'
      partialRootPaths:
        20: 'EXT:my_form/Resources/Private/Partials/'
      templatePathAndFilename: 'EXT:my_form/Resources/Private/Templates/Mails/ContactReceiver.html'

With this configuration the form CE runs into a TypeError Exception because the key ‘20’ (from the partialRootPaths) is returned as an integer from a method (\TYPO3\CMS\Form\Hooks\DataStructureIdentifierHook::extractDottedPathToLastElement()) that has to return a string and has strict typing enabled.

Reviews 2