58% wpo-checker

Code Review | WPO Checker

WordPress plugin WPO Checker scored 58% from 53 tests.

About plugin

  • Plugin page: wpo-checker
  • Plugin version: 0.3
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.3.2
  • WordPress version: 5.8.1
  • First release: Dec 24, 2019
  • Latest release: Feb 9, 2020
  • Number of updates: 20
  • Update frequency: every 2.4 days
  • Top authors: trasweb (100%)

Code review

53 tests

User reviews

2 reviews

Install metrics

20+ active / 422 total downloads

Benchmarks

Plugin footprint 48% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.10MB] [CPU: ▼261.93ms] Passed 4 tests

Analyzing server-side resources used by WPO Checker
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.1236.53 ▲12.50
Dashboard /wp-admin3.16 ▲0.1151.38 ▲5.97
Posts /wp-admin/edit.php3.30 ▲0.1949.55 ▲0.40
Add New Post /wp-admin/post-new.php5.52 ▲0.0996.36 ▼1,049.70
Media Library /wp-admin/upload.php3.10 ▲0.0938.40 ▼4.40
WPO Checker /wp-admin/options-general.php?page=sites_selection_page3.1431.18

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 29 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for WPO Checker
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,677 ▲7215.76 ▲0.278.64 ▼0.7444.71 ▼4.95
Dashboard /wp-admin2,938 ▲855.90 ▲0.06145.59 ▲3.2699.51 ▲5.32
Posts /wp-admin/edit.php2,711 ▲52.69 ▲0.0167.96 ▼8.8189.18 ▲1.91
Add New Post /wp-admin/post-new.php1,659 ▲316.85 ▼1.58382.78 ▼16.50107.90 ▼13.26
Media Library /wp-admin/upload.php1,780 ▲85.02 ▼0.01153.64 ▼4.61107.35 ▼8.90
WPO Checker /wp-admin/options-general.php?page=sites_selection_page1,3392.2165.2456.54

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • Uninstall procedure validation failed for this plugin
    • > Compile error in wp-content/plugins/wpo-checker/src/class-plugin.php+23
    Cannot declare class Trasweb\Plugins\WpoChecker\Plugin, because the name is already in use
  • The plugin did not uninstall correctly, leaving 29 files (0.08MB) in the plugin directory
    • (new file) config/services.php
    • (new file) src/Collections/class-sites.php
    • (new file) config/hooks.php
    • (new file) config/index.php
    • (new file) src/Entities/class-site.php
    • (new file) readme.txt
    • (new file) config/sites.ini
    • (new file) src/Framework/class-autoload.php
    • (new file) LICENSE
    • (new file) index.php
    • ...
  • This plugin does not fully uninstall, leaving 1 option in the database
    • recovery_mode_email_last_sent

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for 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
  • 3× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/wpo-checker/wpo-checker.php
    • > /wp-content/plugins/wpo-checker/index.php
    • > /wp-content/plugins/wpo-checker/uninstall.php
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'Trasweb\\Plugins\\WpoChecker\\Framework\\Service' not found in wp-content/plugins/wpo-checker/config/services.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'Trasweb\\Plugins\\WpoChecker\\Framework\\Hook' not found in wp-content/plugins/wpo-checker/config/hooks.php:15

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 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: webperformance, wpo, webperf

wpo-checker/wpo-checker.php 85% from 13 tests

Analyzing the main PHP file in "WPO Checker" version 0.3
You should first fix the following items:
  • Description: Please don't use more than 140 characters for the plugin description (currently 154 characters long)
  • Domain Path: The domain path folder was not found ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected935 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PHP21254604884
INI17051

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.19
Average class complexity5.00
▷ Minimum class complexity1.00
▷ Maximum class complexity13.00
Average method complexity1.81
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces7
Interfaces0
Traits0
Classes15
▷ Abstract classes00.00%
▷ Concrete classes15100.00%
▷ Final classes533.33%
Methods73
▷ Static methods810.96%
▷ Public methods4257.53%
▷ Protected methods11.37%
▷ Private methods3041.10%
Functions2
▷ Named functions00.00%
▷ Anonymous functions2100.00%
Constants36
▷ Global constants513.89%
▷ Class constants3186.11%
▷ Public constants1651.61%

Plugin size Passed 1 test

Image compression Passed 1 test

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin