90% lh-clear-debug-log-by-cron

Code Review | LH Clear Debug Log by Cron

WordPress plugin LH Clear Debug Log by Cron scored90%from 54 tests.

About plugin

  • Plugin page: lh-clear-debug-lo...
  • Plugin version: 1.01
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.0
  • WordPress version: 6.3.1
  • First release: May 11, 2021
  • Latest release: Jul 20, 2022
  • Number of updates: 3
  • Update frequency: every 145.0 days
  • Top authors: shawfactor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /414 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼3.51ms] Passed 4 tests

This is a short check of server-side resources used by LH Clear Debug Log by Cron
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0236.35 ▼8.06
Dashboard /wp-admin3.31 ▲0.0143.45 ▼7.06
Posts /wp-admin/edit.php3.36 ▲0.0144.99 ▲1.53
Add New Post /wp-admin/post-new.php5.89 ▲0.0189.03 ▲1.03
Media Library /wp-admin/upload.php3.24 ▲0.0132.84 ▲0.06

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

LH Clear Debug Log by Cron: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.16 ▼1.221.66 ▼0.1938.31 ▼5.38
Dashboard /wp-admin2,206 ▲354.83 ▼1.05103.49 ▼17.1439.31 ▼7.12
Posts /wp-admin/edit.php2,089 ▲211.99 ▼0.0140.16 ▲3.7134.62 ▼2.89
Add New Post /wp-admin/post-new.php1,538 ▲523.33 ▲0.23606.05 ▼52.0149.31 ▼8.17
Media Library /wp-admin/upload.php1,382 ▼64.22 ▼0.0397.43 ▼14.3742.83 ▼6.94

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

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 errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: cron, schedule, clear, debug, cron-job

lh-clear-debug-log-by-cron/lh-clear-debug-log-by-cron.php 92% from 13 tests

The primary PHP file in "LH Clear Debug Log by Cron" version 1.01 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Text Domain: The text domain follows the same naming rules as the plugin slug: lowercase characters and dashes

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin96 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2852396

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity15.00
▷ Minimum class complexity15.00
▷ Maximum class complexity15.00
Average method complexity2.17
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods12
▷ Static methods975.00%
▷ Public methods12100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG images were found in this plugin