84% kevinjohn-gallagher-pure-web-brilliants-image-controls

Code Review | Pure Web Brilliant's Image Controls

WordPress plugin Pure Web Brilliant's Image Controls scored 84% from 54 tests.

About plugin

  • Plugin page: kevinjohn-gallagh...
  • Plugin version: 2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0+
  • WordPress version: 6.3.1
  • First release: Jun 19, 2012
  • Latest release: Jul 9, 2012
  • Number of updates: 6
  • Update frequency: every 3.5 days
  • Top authors: kevinjohngallagher (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,015 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼8.59ms] Passed 4 tests

Analyzing server-side resources used by Pure Web Brilliant's Image Controls
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0439.68 ▼1.46
Dashboard /wp-admin3.35 ▲0.0443.87 ▼1.57
Posts /wp-admin/edit.php3.40 ▲0.0445.32 ▼5.50
Add New Post /wp-admin/post-new.php5.93 ▲0.0483.10 ▼24.42
Media Library /wp-admin/upload.php3.27 ▲0.0434.65 ▼2.88

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-posts
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Pure Web Brilliant's Image Controls
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,805 ▲7013.52 ▼0.852.19 ▲0.4744.26 ▼4.63
Dashboard /wp-admin2,211 ▲204.83 ▼1.0597.44 ▼6.1840.02 ▼0.19
Posts /wp-admin/edit.php2,095 ▲62.02 ▲0.0034.54 ▼7.3538.23 ▲1.70
Add New Post /wp-admin/post-new.php1,599 ▲7924.05 ▲0.74622.05 ▼51.5535.53 ▼20.63
Media Library /wp-admin/upload.php1,397 ▲154.24 ▲0.02100.28 ▲0.7241.60 ▼3.57

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

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 take a closer look at the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/kevinjohn-gallagher-pure-web-brilliants-image-controls/kevinjohn_gallagher__image_controls.php

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)
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
There were not plugin tags detected

kevinjohn-gallagher-pure-web-brilliants-image-controls/kevinjohn_gallagher__image_controls.php 92% from 13 tests

The main file in "Pure Web Brilliant's Image Controls" v. 2.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("kevinjohn-gallagher-pure-web-brilliants-image-controls.php" instead of "kevinjohn_gallagher__image_controls.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
There were no executable files found in this plugin428 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP1175180280
JavaScript1575094
CSS116054

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.20
Average class complexity16.00
▷ Minimum class complexity16.00
▷ Maximum class complexity16.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods10
▷ Static methods00.00%
▷ Public methods10100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants150.00%
▷ Class constants150.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin