84% image-upload-for-bbpress

Code Review | Inline Image Upload for BBPress

WordPress plugin Inline Image Upload for BBPress scored84%from 54 tests.

About plugin

  • Plugin page: image-upload-for-...
  • Plugin version: 1.1.19
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-6.4.1
  • WordPress version: 6.3.1
  • First release: Jan 4, 2016
  • Latest release: Nov 30, 2023
  • Number of updates: 76
  • Update frequency: every 38.0 days
  • Top authors: hearken (88.16%)aspengrovestudios (7.89%)annaqq (6.58%)

Code review

54 tests

User reviews

58 reviews

Install metrics

4,000+ active /55,245 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.06MB] [CPU: ▼3.95ms] Passed 4 tests

Server-side resources used by Inline Image Upload for BBPress
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0740.05 ▼0.35
Dashboard /wp-admin3.37 ▲0.0651.16 ▼1.71
Posts /wp-admin/edit.php3.42 ▲0.0651.20 ▼8.59
Add New Post /wp-admin/post-new.php5.95 ▲0.0693.79 ▼1.38
Media Library /wp-admin/upload.php3.29 ▲0.0638.77 ▼4.11
Forum Images /wp-admin/options-general.php?page=hm_bbpui3.2631.19

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 10 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
hm_bbpui_first_activate
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Inline Image Upload for BBPress
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,902 ▲14013.31 ▼0.848.30 ▲6.4739.86 ▼6.06
Dashboard /wp-admin2,196 ▲195.58 ▼0.14104.16 ▲7.6343.88 ▼5.59
Posts /wp-admin/edit.php2,107 ▲42.02 ▲0.0544.65 ▲1.4134.59 ▼9.96
Add New Post /wp-admin/post-new.php1,529 ▲12523.32 ▲5.43688.60 ▲31.5658.99 ▼14.36
Media Library /wp-admin/upload.php1,404 ▲44.21 ▲0.07102.78 ▼27.1342.07 ▼18.32
Forum Images /wp-admin/options-general.php?page=hm_bbpui1,0123.42111.2134.58

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-comments
    • hm_bbpui_first_activate
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
  • 3× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/image-upload-for-bbpress/bbp-image-upload.php:47
    • > PHP Notice
      Undefined variable: potent_slug in wp-content/plugins/image-upload-for-bbpress/plugin-credit.php on line 8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/image-upload-for-bbpress/plugin-credit.php:9

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
5 plugin tags: image, bbpress, media, inline, images

image-upload-for-bbpress/bbp-image-upload.php 92% from 13 tests

The entry point to "Inline Image Upload for BBPress" version 1.1.19 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("image-upload-for-bbpress.php" instead of "bbp-image-upload.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin316 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP25352290
JavaScript12421
CSS12125

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.57
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%
Functions19
▷ Named functions19100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
3 PNG files occupy 0.02MB with 0.00MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/bbpui-screenshot-dialog.png9.92KB5.61KB▼ 43.45%
images/wp_zone_logo.png2.01KB2.14KB0.00%
images/bbpui-screenshot-toolbar.png5.28KB3.32KB▼ 37.05%