89% tmd-wc-delivery-date-time

Code Review | Delivery Date and Time for WooCommerce

WordPress plugin Delivery Date and Time for WooCommerce scored89%from 54 tests.

About plugin

  • Plugin page: tmd-wc-delivery-d...
  • Plugin version: 1.0.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.1-6.1
  • WordPress version: 6.3.1
  • First release: Dec 5, 2022
  • Latest release: Dec 5, 2022
  • Number of updates: 32
  • Update frequency: every 0.1 days
  • Top authors: tmdwp (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /166 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.00MB] [CPU: ▼7.55ms] Passed 4 tests

Server-side resources used by Delivery Date and Time for WooCommerce
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0149.42 ▲11.93
Dashboard /wp-admin3.32 ▼0.0345.82 ▼14.85
Posts /wp-admin/edit.php3.37 ▲0.0145.46 ▼3.94
Add New Post /wp-admin/post-new.php5.90 ▲0.0191.33 ▼8.32
Media Library /wp-admin/upload.php3.24 ▲0.0135.76 ▼3.08

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 30 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Delivery Date and Time for WooCommerce
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,818 ▲4713.19 ▼1.071.95 ▼0.0343.62 ▲2.14
Dashboard /wp-admin2,224 ▲395.82 ▲0.9399.02 ▼1.5439.53 ▼4.71
Posts /wp-admin/edit.php2,107 ▲182.15 ▲0.1536.58 ▼4.7133.16 ▲1.93
Add New Post /wp-admin/post-new.php1,555 ▲4118.22 ▲0.71594.58 ▼82.4466.85 ▲14.15
Media Library /wp-admin/upload.php1,406 ▲214.18 ▼0.0194.26 ▼19.9941.92 ▼4.14

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not 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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
8 plugin tags: delivery-date, delevery-date, delivery-date-and-time, tmd, deleverydate...

tmd-wc-delivery-date-time/delivery-datetime.php 77% from 13 tests

The main PHP file in "Delivery Date and Time for WooCommerce" ver. 1.0.2 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("tmd-wc-delivery-date-time.php" instead of "delivery-datetime.php")
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Domain Path: The domain path is invalid: folder "/i18n/languages/" does not exist

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin1,516 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
CSS341561,227
PHP6166108287
JavaScript2072

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity2.00
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.18
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes150.00%
Methods12
▷ Static methods216.67%
▷ Public methods12100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions8
▷ Named functions00.00%
▷ Anonymous functions8100.00%
Constants2
▷ Global constants2100.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
17 compressed PNG files occupy 0.36MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/css/images/ui-icons_222222_256x240.png3.69KB4.18KB0.00%
assets/css/images/ui-icons_cd0a0a_256x240.png3.69KB4.18KB0.00%
assets/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png0.08KB0.17KB0.00%
assets/css/images/ui-bg_glass_75_e6e6e6_1x400.png0.09KB0.14KB0.00%
screenshot-3.png59.29KB21.38KB▼ 63.94%