Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors
Server metrics [RAM: ▼0.14MB] [CPU: ▼152.96ms] Passed 4 tests
An overview of server-side resources used by Image Cleanup
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.85 ▲0.13 | 33.37 ▲11.75 |
Dashboard /wp-admin | 3.00 ▼0.06 | 33.07 ▼17.21 |
Posts /wp-admin/edit.php | 3.05 ▼0.05 | 36.20 ▼6.56 |
Add New Post /wp-admin/post-new.php | 4.99 ▼0.44 | 73.73 ▼585.58 |
Media Library /wp-admin/upload.php | 3.00 ▲0.00 | 30.52 ▼2.49 |
Image Cleanup /wp-admin/tools.php?page=ImageCleanup | 2.98 | 31.68 |
Server storage [IO: ▲0.09MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
No storage issues were detected
Filesystem: 6 new files
Database: no new tables, 1 new option
New WordPress options |
---|
image_cleanup_version |
Browser metrics Passed 4 tests
Image Cleanup: an overview of browser usage
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,713 ▲117 | 15.83 ▲0.38 | 14.45 ▲5.20 | 49.92 ▼3.59 |
Dashboard /wp-admin | 2,980 ▲46 | 5.95 ▼0.18 | 151.37 ▼4.17 | 104.99 ▼12.65 |
Posts /wp-admin/edit.php | 2,749 ▲10 | 2.71 ▼0.01 | 72.06 ▲9.78 | 97.67 ▲14.06 |
Add New Post /wp-admin/post-new.php | 1,623 ▲125 | 21.40 ▲2.61 | 286.98 ▼102.46 | 102.36 ▼7.14 |
Media Library /wp-admin/upload.php | 1,820 ▲13 | 5.05 ▲0.01 | 146.34 ▼2.54 | 122.65 ▲6.15 |
Image Cleanup /wp-admin/tools.php?page=ImageCleanup | 1,151 | 2.11 | 52.16 | 66.18 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
- This plugin does not fully uninstall, leaving 1 option in the database
- image_cleanup_version
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
- > GET request to /wp-admin/tools.php?page=ImageCleanup
- > Warning in wp-content/plugins/image-cleanup/image-cleanup.plugin.php+1445
count(): Parameter must be an array or an object that implements Countable
- > GET request to /wp-admin/tools.php?page=ImageCleanup
- > Warning in wp-content/plugins/image-cleanup/image-cleanup.plugin.php+1486
unlink(wp-content/uploads/imagecleanup//0): Is a directory
- > GET request to /wp-admin/tools.php?page=ImageCleanup
- > Warning in wp-content/plugins/image-cleanup/image-cleanup.plugin.php+1486
unlink(wp-content/uploads/imagecleanup//0/logs): Is a directory
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
- 9× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/image-cleanup/image-cleanup.file-table.class.php on line 4
- > PHP Fatal error
require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/image-cleanup/image-cleanup.backup-table.class.php on line 4
- > PHP Warning
require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/image-cleanup/image-cleanup.backup-table.class.php on line 4
- > PHP Fatal error
require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/image-cleanup/image-cleanup.backup-table.class.php on line 4
- > PHP Warning
require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/image-cleanup/image-cleanup.file-table.class.php on line 4
- > PHP Warning
require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/image-cleanup/image-cleanup.backup-table.class.php on line 4
- > PHP Warning
Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/image-cleanup/image-cleanup.backup-table.class.php on line 4
- > PHP Warning
Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/image-cleanup/image-cleanup.backup-table.class.php on line 4
- > PHP Warning
Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/image-cleanup/image-cleanup.file-table.class.php on line 4
- > PHP Fatal error
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
3 plugin tags: cleanup, image, clean
image-cleanup/image-cleanup.plugin.php 92% from 13 tests
"Image Cleanup" version 1.9.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("image-cleanup.php" instead of "image-cleanup.plugin.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin1,735 lines of code in 4 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 3 | 429 | 397 | 1,578 |
JavaScript | 1 | 16 | 3 | 157 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.38 |
Average class complexity | 90.33 |
▷ Minimum class complexity | 7.00 |
▷ Maximum class complexity | 201.00 |
Average method complexity | 4.94 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 34.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 3 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 3 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 68 | |
▷ Static methods | 1 | 1.47% |
▷ Public methods | 68 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 12 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 12 | 100.00% |
▷ Public constants | 12 | 100.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
There are no PNG files in this plugin