83% shippit-simplified-australia-shipping

Code Review | Shippit for WooCommerce

WordPress plugin Shippit for WooCommerce scored83%from 54 tests.

About plugin

  • Plugin page: shippit-simplifie...
  • Plugin version: 2.0.1
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Nov 17, 2015
  • Latest release: Nov 13, 2023
  • Number of updates: 98
  • Update frequency: every 29.8 days
  • Top authors: williamonshippit (81.63%)matthewmuscat (19.39%)

Code review

54 tests

User reviews

4 reviews

Install metrics

1,000+ active /22,221 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.15MB] [CPU: ▼10.08ms] Passed 4 tests

Analyzing server-side resources used by Shippit for WooCommerce
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.63 ▲0.1644.01 ▲2.04
Dashboard /wp-admin3.46 ▲0.1145.78 ▼16.64
Posts /wp-admin/edit.php3.58 ▲0.2244.83 ▼5.79
Add New Post /wp-admin/post-new.php6.07 ▲0.1781.76 ▼18.95
Media Library /wp-admin/upload.php3.39 ▲0.1536.29 ▲1.06

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 20 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Shippit for WooCommerce
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,790 ▲5414.25 ▼0.521.80 ▼0.0044.94 ▼2.87
Dashboard /wp-admin2,198 ▲245.64 ▲0.0289.52 ▼10.5239.72 ▼9.22
Posts /wp-admin/edit.php2,100 ▼02.01 ▼0.0135.75 ▼2.6732.63 ▼1.39
Add New Post /wp-admin/post-new.php1,526 ▼123.66 ▲0.53649.61 ▼32.5564.61 ▲8.26
Media Library /wp-admin/upload.php1,397 ▼34.20 ▼0.08101.31 ▲1.7241.07 ▼1.41

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
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 75% from 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 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 5× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WC_Log_Handler_File' not found in wp-content/plugins/shippit-simplified-australia-shipping/includes/class-shippit-log-handler.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/shippit-simplified-australia-shipping/woocommerce-shippit.php:50
    • > PHP Fatal error
      Uncaught Error: Class 'Mamis_Shippit_Object' not found in wp-content/plugins/shippit-simplified-australia-shipping/includes/class-shippit-data-mapper-order-item.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'Mamis_Shippit_Object' not found in wp-content/plugins/shippit-simplified-australia-shipping/includes/class-shippit-data-mapper-order.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'WC_Shipping_Method' not found in wp-content/plugins/shippit-simplified-australia-shipping/includes/class-shippit-method.php:9

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need your attention:
  • Donate link: Invalid url: "NA"
Please take inspiration from this readme.txt

shippit-simplified-australia-shipping/woocommerce-shippit.php 77% from 13 tests

The primary PHP file in "Shippit for WooCommerce" version 2.0.1 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Requires at least: The required version number did not match the one declared in readme.txt ("4.0.0" instead of "6.0.0")
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("shippit-simplified-australia-shipping.php" instead of "woocommerce-shippit.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin3,070 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP156501,0372,709
Markdown32370314
JavaScript18747

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity19.36
▷ Minimum class complexity1.00
▷ Maximum class complexity43.00
Average method complexity2.59
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes14
▷ Abstract classes00.00%
▷ Concrete classes14100.00%
▷ Final classes00.00%
Methods162
▷ Static methods138.02%
▷ Public methods13885.19%
▷ Protected methods2213.58%
▷ Private methods21.23%
Functions6
▷ Named functions350.00%
▷ Anonymous functions350.00%
Constants20
▷ Global constants15.00%
▷ Class constants1995.00%
▷ Public constants19100.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
No PNG files were detected