90% gophr-same-day-shipping-method-for-woocommerce

Code Review | Gophr Same Day Delivery for WooCommerce

WordPress plugin Gophr Same Day Delivery for WooCommerce scored 90% from 54 tests.

About plugin

  • Plugin page: gophr-same-day-sh...
  • Plugin version: 1.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-4.7.4
  • WordPress version: 6.3.1
  • First release: Jun 23, 2016
  • Latest release: May 2, 2017
  • Number of updates: 30
  • Update frequency: every 10.6 days
  • Top authors: gophr (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,412 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
The plugin installed gracefully, with no errors

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

Analyzing server-side resources used by Gophr Same Day Delivery for WooCommerce
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0135.27 ▼5.96
Dashboard /wp-admin3.32 ▲0.0146.78 ▼3.49
Posts /wp-admin/edit.php3.37 ▲0.0149.39 ▼1.53
Add New Post /wp-admin/post-new.php5.90 ▲0.0193.93 ▲3.49
Media Library /wp-admin/upload.php3.24 ▲0.0138.42 ▲5.55

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Gophr Same Day Delivery for WooCommerce
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.17 ▼1.141.65 ▼0.0840.00 ▼6.75
Dashboard /wp-admin2,206 ▲185.86 ▲0.94107.39 ▼6.6139.31 ▼0.26
Posts /wp-admin/edit.php2,092 ▲32.05 ▲0.0638.99 ▼1.6634.64 ▼2.46
Add New Post /wp-admin/post-new.php1,534 ▲1521.18 ▼2.07756.93 ▲163.4357.35 ▼3.58
Media Library /wp-admin/upload.php1,385 ▼34.21 ▼0.07129.73 ▲30.8548.32 ▲3.31

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
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
9 plugin tags: courier, vans, woocommerce, shipping rates, same day delivery...

gophr-same-day-shipping-method-for-woocommerce/gophr-woocommerce-shipping.php 92% from 13 tests

The main PHP script in "Gophr Same Day Delivery for WooCommerce" version 1.1.0 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("gophr-same-day-shipping-method-for-woocommerce.php" instead of "gophr-woocommerce-shipping.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected1,646 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP53953441,646

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity63.00
▷ Minimum class complexity1.00
▷ Maximum class complexity140.00
Average method complexity5.68
▷ Minimum method complexity1.00
▷ Maximum method complexity29.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods53
▷ Static methods23.77%
▷ Public methods4584.91%
▷ Protected methods11.89%
▷ Private methods713.21%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
PNG images were not found in this plugin