Uploaded image for project: 'phpBB'
  1. phpBB
  2. PHPBB-11981

Review/Fix Code Sniffer complaints

XMLWordPrintable

    • Icon: Task Task
    • Resolution: Fixed
    • Icon: Blocker Blocker
    • 3.1.0-a2
    • 3.1.0-a1
    • None
    • None

      afischer@leonard:/var/www/projects/phpbb3 (task/code-sniffer) build $ phing sniff
      Buildfile: /var/www/projects/phpbb3/build/build.xml
       
      phpBB > sniff:
       
       
      FILE: /var/www/projects/phpbb3/phpBB/includes/functions_messenger.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       1417 | ERROR | Inline control structures are not allowed
            |       | (Generic.ControlStructures.InlineControlStructure.NotAllowed)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/includes/acp/acp_database.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       491 | ERROR | Arguments with default values must be at the end of the argument
           |       | list (PEAR.Functions.ValidDefaultValue.NotAtEnd)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/includes/acp/auth.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       1102 | ERROR | Arguments with default values must be at the end of the
            |       | argument list (PEAR.Functions.ValidDefaultValue.NotAtEnd)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/includes/acp/acp_styles.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       891 | ERROR | Inline control structures are not allowed
           |       | (Generic.ControlStructures.InlineControlStructure.NotAllowed)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/includes/captcha/captcha_gd_wave.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       267 | ERROR | Arguments with default values must be at the end of the argument
           |       | list (PEAR.Functions.ValidDefaultValue.NotAtEnd)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/includes/ucp/ucp_notifications.php
      --------------------------------------------------------------------------------
      FOUND 2 ERROR(S) AFFECTING 2 LINE(S)
      --------------------------------------------------------------------------------
       170 | ERROR | Arguments with default values must be at the end of the argument
           |       | list (PEAR.Functions.ValidDefaultValue.NotAtEnd)
       217 | ERROR | Arguments with default values must be at the end of the argument
           |       | list (PEAR.Functions.ValidDefaultValue.NotAtEnd)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/includes/functions_compress.php
      --------------------------------------------------------------------------------
      FOUND 2 ERROR(S) AFFECTING 2 LINE(S)
      --------------------------------------------------------------------------------
       398 | ERROR | Arguments with default values must be at the end of the argument
           |       | list (PEAR.Functions.ValidDefaultValue.NotAtEnd)
       672 | ERROR | Arguments with default values must be at the end of the argument
           |       | list (PEAR.Functions.ValidDefaultValue.NotAtEnd)
      --------------------------------------------------------------------------------
       
      Time: 43.17 seconds, Memory: 61.25Mb
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/template/context.php
      --------------------------------------------------------------------------------
      FOUND 2 ERROR(S) AFFECTING 2 LINE(S)
      --------------------------------------------------------------------------------
       288 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
       299 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/template/twig/node/includephp.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       26 | ERROR | Arguments with default values must be at the end of the argument
          |       | list (PEAR.Functions.ValidDefaultValue.NotAtEnd)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/search/fulltext_native.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       852 | ERROR | Functions must not contain multiple empty lines in a row; found
           |       | 2 empty lines
           |       | (Squiz.WhiteSpace.SuperfluousWhitespace.EmptyLines)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/user.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       345 | ERROR | Functions must not contain multiple empty lines in a row; found
           |       | 2 empty lines
           |       | (Squiz.WhiteSpace.SuperfluousWhitespace.EmptyLines)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/session.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       1237 | ERROR | Functions must not contain multiple empty lines in a row; found
            |       | 2 empty lines
            |       | (Squiz.WhiteSpace.SuperfluousWhitespace.EmptyLines)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/extension/metadata_manager.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       172 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/extension/manager.php
      --------------------------------------------------------------------------------
      FOUND 3 ERROR(S) AFFECTING 3 LINE(S)
      --------------------------------------------------------------------------------
       237 | ERROR | Inline control structures are not allowed
           |       | (Generic.ControlStructures.InlineControlStructure.NotAllowed)
       314 | ERROR | Inline control structures are not allowed
           |       | (Generic.ControlStructures.InlineControlStructure.NotAllowed)
       391 | ERROR | Inline control structures are not allowed
           |       | (Generic.ControlStructures.InlineControlStructure.NotAllowed)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/db/tools.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       36 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but found
          |       | "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/db/driver/mysqli.php
      --------------------------------------------------------------------------------
      FOUND 3 ERROR(S) AFFECTING 3 LINE(S)
      --------------------------------------------------------------------------------
       50 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but found
          |       | "NULL" (Generic.PHP.LowerCaseConstant.Found)
       54 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but found
          |       | "NULL" (Generic.PHP.LowerCaseConstant.Found)
       64 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but found
          |       | "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/db/driver/mssql.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       262 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/db/driver/postgres.php
      --------------------------------------------------------------------------------
      FOUND 3 ERROR(S) AFFECTING 3 LINE(S)
      --------------------------------------------------------------------------------
       331 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
       459 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
       479 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/db/driver/mssqlnative.php
      --------------------------------------------------------------------------------
      FOUND 2 ERROR(S) AFFECTING 2 LINE(S)
      --------------------------------------------------------------------------------
       198 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
       430 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: .../projects/phpbb3/phpBB/phpbb/db/migration/data/v310/style_update_p2.php
      --------------------------------------------------------------------------------
      FOUND 4 ERROR(S) AFFECTING 4 LINE(S)
      --------------------------------------------------------------------------------
        59 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
        71 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
        86 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
       115 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: ...var/www/projects/phpbb3/phpBB/phpbb/db/migration/data/v310/teampage.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       30 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but found
          |       | "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: ...ww/projects/phpbb3/phpBB/phpbb/db/migration/data/v310/notifications.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       37 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but found
          |       | "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: .../phpbb3/phpBB/phpbb/db/migration/data/v310/notifications_schema_fix.php
      --------------------------------------------------------------------------------
      FOUND 3 ERROR(S) AFFECTING 3 LINE(S)
      --------------------------------------------------------------------------------
       29 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but found
          |       | "NULL" (Generic.PHP.LowerCaseConstant.Found)
       40 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but found
          |       | "NULL" (Generic.PHP.LowerCaseConstant.Found)
       76 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but found
          |       | "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: ...var/www/projects/phpbb3/phpBB/phpbb/notification/type/approve_topic.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       37 | ERROR | Whitespace found at end of line
          |       | (Squiz.WhiteSpace.SuperfluousWhitespace.EndLine)
      --------------------------------------------------------------------------------
       
       
      FILE: ...r/www/projects/phpbb3/phpBB/phpbb/event/kernel_exception_subscriber.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       74 | ERROR | Functions must not contain multiple empty lines in a row; found 2
          |       | empty lines (Squiz.WhiteSpace.SuperfluousWhitespace.EmptyLines)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/auth/provider/oauth/oauth.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       282 | ERROR | Arguments with default values must be at the end of the argument
           |       | list (PEAR.Functions.ValidDefaultValue.NotAtEnd)
      --------------------------------------------------------------------------------
       
       
      FILE: ...r/www/projects/phpbb3/phpBB/phpbb/auth/provider/oauth/token_storage.php
      --------------------------------------------------------------------------------
      FOUND 2 ERROR(S) AFFECTING 2 LINE(S)
      --------------------------------------------------------------------------------
        81 | ERROR | PHP keywords must be lowercase; expected "instanceof" but found
           |       | "instanceOf" (Generic.PHP.LowerCaseKeyword.Found)
       241 | ERROR | PHP keywords must be lowercase; expected "instanceof" but found
           |       | "instanceOf" (Generic.PHP.LowerCaseKeyword.Found)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/auth/provider/ldap.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       99 | ERROR | Functions must not contain multiple empty lines in a row; found 2
          |       | empty lines (Squiz.WhiteSpace.SuperfluousWhitespace.EmptyLines)
      --------------------------------------------------------------------------------
       
       
      FILE: /var/www/projects/phpbb3/phpBB/phpbb/feed/base.php
      --------------------------------------------------------------------------------
      FOUND 1 ERROR(S) AFFECTING 1 LINE(S)
      --------------------------------------------------------------------------------
       153 | ERROR | TRUE, FALSE and NULL must be lowercase; expected "null" but
           |       | found "NULL" (Generic.PHP.LowerCaseConstant.Found)
      --------------------------------------------------------------------------------
       
      Time: 11.18 seconds, Memory: 26.50Mb
       
       
      BUILD FINISHED
       
      Total time: 54.5186 seconds
      

            bantu Andreas Fischer [X] (Inactive)
            bantu Andreas Fischer [X] (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: