10% wp-phpbb-bridge

Code Review | WP phpBB Bridge

WordPress plugin WP phpBB Bridge scored10%from 54 tests.

About plugin

  • Plugin page: wp-phpbb-bridge
  • Plugin version: 2.0.7
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.4-3.3.1
  • WordPress version: 6.3.1
  • First release: Feb 2, 2011
  • Latest release: Oct 27, 2012
  • Number of updates: 487
  • Update frequency: every 1.3 days
  • Top authors: merianos (92.61%)zeoz (7.6%)

Code review

54 tests

User reviews

11 reviews

Install metrics

30+ active /35,726 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The following installer errors require your attention
  • Install procedure validation failed for this plugin
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)

Server metrics [RAM: ▼1.78MB] [CPU: ▼52.18ms] Passed 4 tests

Server-side resources used by WP phpBB Bridge
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.20 ▼1.264.75 ▼36.10
Dashboard /wp-admin2.23 ▼1.077.09 ▼46.95
Posts /wp-admin/edit.php2.24 ▼1.126.16 ▼40.66
Add New Post /wp-admin/post-new.php2.23 ▼3.666.47 ▼85.02
Media Library /wp-admin/upload.php2.23 ▼1.007.11 ▼30.93
Settings /wp-admin/admin.php?page=wpbb_settings2.235.94
Donators /wp-admin/admin.php?page=wpbb_donators2.236.99
WP phpBB Bridge /wp-admin/admin.php?page=wpbb2.237.08

Server storage [IO: ▲1.73MB] [DB: ▲0.05MB] Passed 3 tests

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 52 new files
Database: no new tables, 12 new options
New WordPress options
widget_phpbb3-users-widget
db_upgraded
widget_phpbb3-meta-widget
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
widget_phpbb3-links-widget
widget_phpbb3-posts-widget
wpbb_version
...

Browser metrics Passed 4 tests

An overview of browser requirements for WP phpBB Bridge
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,944 ▲20913.71 ▼1.076.32 ▲4.6038.09 ▼4.82
Dashboard /wp-admin2,230 ▲454.93 ▼0.95100.41 ▼13.0581.53 ▲32.48
Posts /wp-admin/edit.php2,127 ▲382.01 ▲0.0037.38 ▲1.2534.65 ▼3.00
Add New Post /wp-admin/post-new.php1,703 ▲18922.27 ▲4.79755.49 ▲71.9450.81 ▼0.53
Media Library /wp-admin/upload.php1,427 ▲394.17 ▼0.04104.97 ▲2.8877.71 ▲32.89
Settings /wp-admin/admin.php?page=wpbb_settings1,3491.8826.9327.90
Donators /wp-admin/admin.php?page=wpbb_donators1,8652.1626.5337.28
WP phpBB Bridge /wp-admin/admin.php?page=wpbb1,3651.8125.1432.52

Uninstaller [IO: ▲0.00MB] [DB: ▲0.05MB] 50% from 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • This plugin cannot be uninstalled
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)
  • Zombie WordPress options detected upon uninstall: 12 options
    • theysaidso_admin_options
    • wpbb_version
    • widget_phpbb3-links-widget
    • widget_phpbb3-users-widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • wpbb_t
    • db_upgraded
    • widget_phpbb3-meta-widget
    • ...

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These errors were triggered by the plugin
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > User notice in wp-includes/functions.php+5905
    Function register_uninstall_hook was called incorrectly. Only a static class method or function can be used in an uninstall hook. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.)
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Deprecated in wp-content/plugins/wp-phpbb-bridge/inc/wpbb_admin.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; WPBB_AdminPanel has a deprecated constructor
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Deprecated in wp-content/plugins/wp-phpbb-bridge/inc/widgets/wpbb_users_widget.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; wpbb_users_widget has a deprecated constructor
  • 12 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Deprecated in wp-content/plugins/wp-phpbb-bridge/wp_phpbb_bridge.php+223
    Function create_function() is deprecated
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Deprecated in wp-content/plugins/wp-phpbb-bridge/inc/widgets/wpbb_links_widget.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; wpbb_links_widget has a deprecated constructor
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Deprecated in wp-content/plugins/wp-phpbb-bridge/inc/widgets/wpbb_meta_widget.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; wpbb_meta_widget has a deprecated constructor
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Deprecated in wp-content/plugins/wp-phpbb-bridge/inc/widgets/wpbb_topics_widget.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; wpbb_topics_widget has a deprecated constructor
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in wpbb_users_widget is deprecated since version 4.3.0! Use __construct() instead.
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in wpbb_links_widget is deprecated since version 4.3.0! Use __construct() instead.
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in wpbb_meta_widget is deprecated since version 4.3.0! Use __construct() instead.
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in wpbb_topics_widget is deprecated since version 4.3.0! Use __construct() instead.
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > User deprecated in wp-includes/functions.php+5737
    Function get_bloginfo was called with an argument that is deprecated since version 2.2.0! The home option is deprecated for the family of bloginfo() functions. Use the url option instead.
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > User deprecated in wp-includes/functions.php+5643
    File rss.php is deprecated since version 3.0.0! Use wp-includes/class-simplepie.php instead.
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Notice in wp-includes/rss.php+502
    Undefined property: stdClass::$error
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Notice in wp-content/plugins/wp-phpbb-bridge/inc/admin_pages/dashboard.php+177
    Trying to get property 'items' of non-object
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Warning in wp-content/plugins/wp-phpbb-bridge/inc/admin_pages/dashboard.php+198
    array_slice() expects parameter 1 to be array, null given
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Warning in wp-content/plugins/wp-phpbb-bridge/inc/admin_pages/dashboard.php+192
    array_merge(): Expected parameter 2 to be an array, null given
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Warning in wp-content/plugins/wp-phpbb-bridge/inc/admin_pages/dashboard.php+194
    usort() expects parameter 1 to be array, null given
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Warning in wp-content/plugins/wp-phpbb-bridge/inc/admin_pages/dashboard.php+196
    array_reverse() expects parameter 1 to be array, null given
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Warning in wp-content/plugins/wp-phpbb-bridge/inc/admin_pages/dashboard.php+200
    Invalid argument supplied for foreach()

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 11× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/wp-phpbb-bridge/inc/admin_pages/donators.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function bloginfo() in wp-content/plugins/wp-phpbb-bridge/inc/wpbbreset/wpbbreset.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-phpbb-bridge/wp_phpbb_bridge.php:29
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/wp-phpbb-bridge/inc/widgets/wpbb_links_widget.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-phpbb-bridge/inc/wpbb_admin.php:142
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/wp-phpbb-bridge/inc/widgets/wpbb_users_widget.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/wp-phpbb-bridge/inc/admin_pages/dashboard.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/wp-phpbb-bridge/inc/wpbb_functions.php:189
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/wp-phpbb-bridge/inc/widgets/wpbb_topics_widget.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/wp-phpbb-bridge/inc/widgets/wpbb_meta_widget.php:3

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please take a look at the following user-side issues
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Console-api (warning) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28609 "jQuery.Deferred exception: $(...).live is not a function" "TypeError: $(...).live is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/wp-phpbb-bridge/js/wp_phpbb_bridge.js?ver=6.3.1:26:43)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1:2:27292)" undefined
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpbb
    • > Javascript (severe) in unknown
    /wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.3.1 1:28721 Uncaught TypeError: $(...).live is not a function

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: These screenshots require images: #1 (New menu position), #3 (Organized dashboard for one look fast informations), #4 (Recent donators widget in WP phpBB Bridge dashboard), #5 (One look settings informations), #6 (One look server settings information), #7 (Better organized settings page), #11 (List of donators with serial number), #12 (Widgets coming with WP phpBB Bridge), #13 (WP phpBB Bridge Users Widget), #14 (WP phpBB Bridge Meta Widget), #15 (WP phpBB Bridge Posts Widget), #16 (WP phpBB Bridge Links Widget), #17 (WP phpBB Bridge Users Widget, front end), #18 (WP phpBB Bridge Posts Widget, front end), #19 (WP phpBB Bridge Meta Widget, front end), #20 (WP phpBB Bridge Links Widget, front end)
The official readme.txt is a good inspiration

wp-phpbb-bridge/wp_phpbb_bridge.php 85% from 13 tests

The principal PHP file in "WP phpBB Bridge" v. 2.0.7 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("wp-phpbb-bridge.php" instead of "wp_phpbb_bridge.php")
  • Description: Keep the plugin description shorter than 140 characters (currently 271 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Good job! No executable or dangerous file extensions detected6,571 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PO File81,5922,0103,368
PHP114191733,000
JavaScript1311201
CSS2002

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity19.00
▷ Minimum class complexity6.00
▷ Maximum class complexity43.00
Average method complexity3.45
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods44
▷ Static methods00.00%
▷ Public methods44100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions24
▷ Named functions24100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants8100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
4 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/updown.png2.11KB0.92KB▼ 56.59%
img/pixel.png0.90KB0.09KB▼ 89.69%
img/bridge.png0.61KB0.60KB▼ 0.97%
img/bridge_32x32.png1.42KB1.41KB0.34%