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

Q&A captcha plug-in still throws PHP 7.2.x countable warning

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.2.5
    • Fix Version/s: 3.2.8-RC1
    • Component/s: Other
    • Labels:
      None
    • Environment:
      phpBB 3.2.5, PHP 7.2.x

      Description

      Visited phpBB 3.2.5 site from support forum user, and noticed the following warning was being generated on the registration page:

      [phpBB Debug] PHP Warning: in file [ROOT]/phpbb/captcha/plugins/qa.php on line 87: count(): Parameter must be an array or an object that implements Countable
      [phpBB Debug] PHP Warning: in file [ROOT]/phpbb/captcha/plugins/qa.php on line 104: count(): Parameter must be an array or an object that implements Countable

      Code inspection of the /phpbb/captcha/plugins/qa.php module in phpBB 3.2.5 confirms that "var $question_ids" doesn't have an array() declaration for PHP 7.2+.  Reviewing other uses of "count()" in the qa.php module didn't reveal any other omissions (at least not obvious enough for me to identify).

        Attachments

          Activity

            People

            • Assignee:
              Marc Marc
              Reporter:
              EA117 EA117
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: