68% clevererror

Code Review | CleverError - Make your error pages more clever

WordPress plugin CleverError - Make your error pages more clever scored68%from 54 tests.

About plugin

  • Plugin page: clevererror
  • Plugin version: 0.20
  • PHP version: 7.4.16
  • WordPress compatibility: 2.0.0-3.5.1
  • WordPress version: 6.3.1
  • First release: Mar 8, 2013
  • Latest release: May 24, 2013
  • Number of updates: 6
  • Update frequency: every 12.8 days
  • Top authors: tompod (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

10+ active /1,795 total downloads

Benchmarks

Plugin footprint 65% 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.94MB] [CPU: ▼35.40ms] Passed 4 tests

This is a short check of server-side resources used by CleverError - Make your error pages more clever
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.15 ▲0.17
Dashboard /wp-admin3.00 ▼0.3020.53 ▼31.91
Posts /wp-admin/edit.php3.01 ▼0.3520.77 ▼29.87
Add New Post /wp-admin/post-new.php3.00 ▼2.8821.89 ▼68.02
Media Library /wp-admin/upload.php3.00 ▼0.2222.34 ▼11.78
CleverError /wp-admin/plugins.php?page=clevererror/clevererror.php3.0120.31

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for CleverError - Make your error pages more clever
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲9413.12 ▼1.164.97 ▲3.1844.55 ▲2.83
Dashboard /wp-admin2,207 ▲365.78 ▼0.0797.86 ▼2.8338.07 ▼20.44
Posts /wp-admin/edit.php2,075 ▼142.02 ▲0.0336.37 ▼4.0233.69 ▼3.37
Add New Post /wp-admin/post-new.php1,527 ▼623.10 ▼0.10668.35 ▼16.4658.01 ▲4.97
Media Library /wp-admin/upload.php1,392 ▲14.16 ▼0.0295.50 ▼8.6842.65 ▼1.79
CleverError /wp-admin/plugins.php?page=clevererror/clevererror.php8992.0224.4432.01

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Uninstall procedure validation failed for this plugin
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded

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 errors were triggered by the plugin
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/plugins.php?page=clevererror/clevererror.php
    • > User deprecated in wp-includes/functions.php+5737
    Function has_cap was called with an argument that is deprecated since version 2.0.0! Usage of user levels is deprecated. Use capabilities instead.
    • > GET request to /wp-admin/plugins.php?page=clevererror/clevererror.php
    • > Notice in wp-content/plugins/clevererror/clevererror.php+41
    Undefined index: clevererror_submit
    • > GET request to /wp-admin/plugins.php?page=clevererror/clevererror.php
    • > Notice in wp-content/plugins/clevererror/clevererror.php+51
    Trying to access array offset on value of type bool

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Almost there! Just fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/clevererror/clevererror.php:32

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 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Please fix the following attributes:
  • Tags: Too many tags (11 tag instead of maximum 10); only the first 5 tags are used in your directory listing
You can take inspiration from this readme.txt

clevererror/clevererror.php 92% from 13 tests

The primary PHP file in "CleverError - Make your error pages more clever" version 0.20 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 207 characters long)

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
Good job! No executable or dangerous file extensions detected105 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP11824105

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.21
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%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

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