Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-22977

Twig Helper ezpublish.legacy.get( 'path' ) raises an error

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Medium Medium
    • None
    • 5.3
    • None

    Description

      When, in a template, you try to access legacy variables using ezpublish.legacy, it raise an error.

      Steps to reproduce:
      in a template (ex: pagelayout.html.twig), try to display {{ ezpublish.legacy.get( 'path' ) }} and you will get an error like this :

      ContextErrorException: Warning: array_key_exists() expects parameter 2 to be array, null given in /Users/huckflorent/Sites/e-learning/vendor/symfony/symfony/src/Symfony/Component/HttpFoundation/ParameterBag.php line 106
      

      And if you just dump ezpublish.legacy, metadata parameters is null.

      maybe this is linked to https://jira.ez.no/browse/EZP-22897?jql=text%20~%20%22ezpublish.legacy%22
      ?

      Best

      Attachments

        Activity

          People

            Unassigned Unassigned
            Florent.Huck-obsolete@ez.no Florent Huck (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: