Uploaded image for project: 'phpBB3'
  1. phpBB3
  2. PHPBB3-15314

Wrong class constructor definition for convertor component

    Details

      Description

      In the namespaced file install/convert/convert.php, constructor for the class convertor is defined in 'old' style

      https://github.com/phpbb/phpbb/blob/3.2.x/phpBB/install/convert/convert.php#L56

       

      As per PHP manual http://php.net/manual/en/language.oop5.decon.php

      As of PHP 5.3.3, methods with the same name as the last element of a namespaced class name will no longer be treated as constructor. This change doesn't affect non-namespaced classes.

      So, the constructor doesn't work, which leads to errors like

      Fatal error: Call to a member function error() on null in /install/convertors/functions_phpbb20.php on line 1348

      See https://www.phpbb.com/community/viewtopic.php?f=556&t=2434161

       

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Marc Marc
                Reporter:
                rxu rxu
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: