84% del-post-rev

Code Review | Del-Post-Rev

WordPress plugin Del-Post-Rev scored84%from 54 tests.

About plugin

  • Plugin page: del-post-rev
  • Plugin version: 1.0
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-5.6
  • WordPress version: 6.3.1
  • First release: Apr 14, 2018
  • Latest release: Mar 1, 2021
  • Number of updates: 8
  • Update frequency: every 131.5 days
  • Top authors: keksus (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /845 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.03MB] [CPU: ▼1.72ms] Passed 4 tests

A check of server-side resources used by Del-Post-Rev
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0338.96 ▼4.97
Dashboard /wp-admin3.34 ▲0.0452.03 ▲0.89
Posts /wp-admin/edit.php3.39 ▲0.0445.73 ▼2.39
Add New Post /wp-admin/post-new.php5.92 ▲0.0493.12 ▲2.48
Media Library /wp-admin/upload.php3.26 ▲0.0433.88 ▼0.42
Del-Post-Rev /wp-admin/options-general.php?page=dpr_settings3.0825.23

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Del-Post-Rev
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,810 ▲6414.64 ▲0.061.74 ▲0.0444.39 ▲0.66
Dashboard /wp-admin2,213 ▲224.85 ▼0.26106.36 ▼1.4642.47 ▼0.11
Posts /wp-admin/edit.php2,093 ▲72.01 ▼0.0233.74 ▼4.6432.82 ▼2.62
Add New Post /wp-admin/post-new.php1,533 ▲1418.27 ▼4.96649.40 ▲41.4659.62 ▲11.78
Media Library /wp-admin/upload.php1,392 ▲44.16 ▼0.06101.88 ▼3.1546.72 ▲4.19
Del-Post-Rev /wp-admin/options-general.php?page=dpr_settings9032.0425.1126.77

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/options-general.php?page=dpr_settings
    • > Warning in wp-content/plugins/del-post-rev/del-post-rev.php+69
    Use of undefined constant jquery - assumed 'jquery' (this will throw an Error in a future version of PHP)
    • > GET request to /wp-admin/options-general.php?page=dpr_settings
    • > Notice in wp-content/plugins/del-post-rev/del-post-rev.php+106
    Undefined index: dpr_submit

SRP Passed 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: Add an image for screenshot #1 (Admin settings page)
You can take inspiration from this readme.txt

del-post-rev/del-post-rev.php Passed 13 tests

"Del-Post-Rev" version 1.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
43 characters long description:
Delete post revisions and disable revisions

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 detected526 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
CSS1732352
PHP12014150
JavaScript13012
Markdown19012

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.13
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%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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