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

eZLocale::localeList can't be called twice with different arguments

    XMLWordPrintable

Details

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

    Description

      Those 2 functions will return the same thing, the second should return an array of objects

              print_r(eZLocale::localeList(false, false));
              print_r(eZLocale::localeList(true, false));
      

      It comes from the cache used in this function:

              $locales =& $GLOBALS['eZLocaleLocaleStringList'];
              if ( !is_array( $locales ) )
              {
                 // generate $locales
              }
      

      A quick fix would be to use an hash for this cache that relies on $asObject and $withVariations

      Attachments

        Activity

          People

            unknown unknown
            enzo enzo
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: