79% bbp-topic-count

Code Review | bbp topic count

WordPress plugin bbp topic count scored 79% from 54 tests.

About plugin

  • Plugin page: bbp-topic-count
  • Plugin version: 3.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.2
  • WordPress version: 6.3.1
  • First release: Feb 28, 2014
  • Latest release: Apr 7, 2023
  • Number of updates: 126
  • Update frequency: every 26.4 days
  • Top authors: Robin W (100%)

Code review

54 tests

User reviews

15 reviews

Install metrics

800+ active / 27,965 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▲1.48ms] Passed 4 tests

An overview of server-side resources used by bbp topic count
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.06 ▼0.07
Dashboard /wp-admin3.31 ▲0.0145.16 ▲1.87
Posts /wp-admin/edit.php3.36 ▲0.0147.60 ▲1.22
Add New Post /wp-admin/post-new.php5.89 ▲0.0193.25 ▲7.45
Media Library /wp-admin/upload.php3.24 ▲0.0135.64 ▲2.91
bbp topic count /wp-admin/options-general.php?page=bbp-topic-count3.2030.90

Server storage [IO: ▲0.16MB] [DB: ▲0.00MB] Passed 3 tests

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for bbp topic count
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲1513.16 ▼1.651.67 ▼0.0841.44 ▲0.85
Dashboard /wp-admin2,210 ▲45.90 ▲0.11106.96 ▲9.1241.84 ▲2.80
Posts /wp-admin/edit.php2,093 ▲11.99 ▼0.0339.32 ▲3.8933.72 ▲1.09
Add New Post /wp-admin/post-new.php1,545 ▲1118.34 ▼4.94587.13 ▼81.4763.47 ▲1.45
Media Library /wp-admin/upload.php1,392 ▲14.23 ▲0.0894.07 ▼8.6941.74 ▼2.00
bbp topic count /wp-admin/options-general.php?page=bbp-topic-count1,0852.0826.3827.56

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% 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
Almost there! Just fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/bbp-topic-count/includes/display.php
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bbp-topic-count/includes/settings.php:79
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/bbp-topic-count/bbp-topic-count.php:37
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/bbp-topic-count/includes/shortcodes.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
5 plugin tags: bbp, forum, bbpress, topic, count

bbp-topic-count/bbp-topic-count.php Passed 13 tests

The primary PHP file in "bbp topic count" version 3.1 is used by WordPress to initiate all plugin functionality
126 characters long description:
This plugin for bbPress shows any combination of the total topics, replies and post count under the avatar on each topic/reply

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin771 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP516582771

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions16
▷ Named functions16100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
No PNG files were detected