90% edd-variable-defaults-update

Code Review | EDD Variable Defaults Update

WordPress plugin EDD Variable Defaults Update scored 90% from 54 tests.

About plugin

  • Plugin page: edd-variable-defa...
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-4.9.4
  • WordPress version: 6.3.1
  • First release: Mar 8, 2018
  • Latest release: Mar 16, 2018
  • Number of updates: 4
  • Update frequency: every 2.0 days
  • Top authors: wooninjas (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 677 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼13.32ms] Passed 4 tests

A check of server-side resources used by EDD Variable Defaults Update
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.26 ▼0.16
Dashboard /wp-admin3.33 ▲0.0244.15 ▼6.39
Posts /wp-admin/edit.php3.38 ▲0.0243.76 ▼10.37
Add New Post /wp-admin/post-new.php5.91 ▲0.0282.37 ▼33.65
Media Library /wp-admin/upload.php3.25 ▲0.0237.86 ▼2.86

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 9 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
db_upgraded
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for EDD Variable Defaults Update
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,809 ▲7413.28 ▼0.891.65 ▼0.2146.00 ▼0.92
Dashboard /wp-admin2,218 ▲334.85 ▲0.02106.48 ▼3.4140.68 ▼6.23
Posts /wp-admin/edit.php2,100 ▲111.97 ▼0.0835.18 ▼4.8332.85 ▼4.83
Add New Post /wp-admin/post-new.php1,523 ▼2117.58 ▼5.45703.41 ▲28.2661.34 ▲8.86
Media Library /wp-admin/upload.php1,394 ▲94.18 ▲0.0794.39 ▼25.9743.29 ▼5.37

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
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

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

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
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
8 plugin tags: edd variable, bulk variable pricing, easy digital downloads, edd, easy digital downloads variable...

edd-variable-defaults-update/edd-variable-defaults-update.php 92% from 13 tests

This is the main PHP file of "EDD Variable Defaults Update" version 1.0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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 detected433 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP492105381
JavaScript112048
CSS1004

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity22.50
▷ Minimum class complexity8.00
▷ Maximum class complexity37.00
Average method complexity3.35
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods18
▷ Static methods316.67%
▷ Public methods1477.78%
▷ Protected methods00.00%
▷ Private methods422.22%
Functions3
▷ Named functions266.67%
▷ Anonymous functions133.33%
Constants4
▷ Global constants375.00%
▷ Class constants125.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG files were detected