Project

General

Profile

Actions

Bug #102264

closed

#1476107295 TYPO3\CMS\Core\Error\Exception PHP Warning: Array to string conversion in /var/www/html/vendor/typo3fluid/fluid/src/Core/Parser/SyntaxTree/Abs

Added by Thomas Sam Wittich 7 months ago. Updated 10 days ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Fluid
Target version:
-
Start date:
2023-10-26
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
11
PHP Version:
8.1
Tags:
fluid, viewhelper, abstract-viewhelper
Complexity:
Is Regression:
Sprint Focus:

Description

Hi,
Exception throws at: /var/www/html/vendor/typo3fluid/fluid/src/Core/Parser/SyntaxTree/AbstractNode.php line 73
That means:

    {
        if (is_object($value) && !method_exists($value, '__toString')) {
            throw new Parser\Exception('Cannot cast object of type "' . get_class($value) . '" to string.', 1273753083);
        }
        $output = (string)$value;
        return $output;
    }

The line $output = (string)$value; throws it, but the error in mho is in the preceeding if statement: It's asking for object, but not for an array. (Which is the case there).


Files

Actions #1

Updated by Garvin Hicking 7 months ago

Can you add info about from which fluid markup / operation this actually stems? A possible fix would involve testcases, so it would be good to know how it can be reproduced.

Actions #2

Updated by Stefan Bürk 6 months ago

Created issue in the fluid repository for it:

https://github.com/TYPO3/Fluid/issues/826

Actions #3

Updated by Riccardo De Contardi 13 days ago

Is this issue still valid? Looking at https://github.com/TYPO3/Fluid/issues/826 I see it has been closed on Nov 21, 2023

Actions #4

Updated by Thomas Sam Wittich 13 days ago

Hi Riccardo, thank you coming back to it. Should be closed.
Thx, Thomas

Actions #5

Updated by Riccardo De Contardi 10 days ago

  • Status changed from New to Closed
  • Target version deleted (Candidate for patchlevel)

@ Thomas Sam Wittich Thank you for your quick reply;

Closing this issue in agreement with the reporter.

If you think that this is the wrong decision or experience the issue again, please reopen it or open a new issue with a reference to this one.

Thank you.

Actions

Also available in: Atom PDF