68% ship-to-ecourier

Code Review | Ship To eCourier

WordPress plugin Ship To eCourier scored 68% from 54 tests.

About plugin

  • Plugin page: ship-to-ecourier
  • Plugin version: 1.1.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.2.0
  • WordPress version: 6.3.1
  • First release: May 4, 2021
  • Latest release: Apr 5, 2023
  • Number of updates: 12
  • Update frequency: every 58.5 days
  • Top authors: simongomes02 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 605 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.04MB] [CPU: ▼0.78ms] Passed 4 tests

Analyzing server-side resources used by Ship To eCourier
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0436.64 ▼6.36
Dashboard /wp-admin3.34 ▲0.0448.53 ▼2.66
Posts /wp-admin/edit.php3.45 ▲0.1049.13 ▲1.93
Add New Post /wp-admin/post-new.php5.94 ▲0.0697.77 ▲7.81
Media Library /wp-admin/upload.php3.26 ▲0.0338.35 ▲3.96

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 53 new files
Database: 1 new table, 9 new options
New tables
wp_ste_shipped_orders
New WordPress options
widget_recent-posts
ste_installed
widget_recent-comments
ste_version
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
ste_settings

Browser metrics Passed 4 tests

This is an overview of browser requirements for Ship To eCourier
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,840 ▲10513.23 ▼0.931.54 ▼0.3139.20 ▼4.45
Dashboard /wp-admin2,249 ▲615.85 ▲0.0495.24 ▼33.0381.75 ▲21.14
Posts /wp-admin/edit.php2,129 ▲401.98 ▼0.0439.09 ▲2.0034.78 ▼2.71
Add New Post /wp-admin/post-new.php1,552 ▲1923.25 ▲0.05710.43 ▲26.1050.87 ▲3.96
Media Library /wp-admin/upload.php1,422 ▲344.27 ▲0.06102.01 ▼1.2177.21 ▲31.03

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • The plugin did not uninstall successfully, leaving 1 table in the database
    • wp_ste_shipped_orders
  • Zombie WordPress options were found after uninstall: 8 options
    • widget_recent-posts
    • ste_version
    • widget_theysaidso_widget
    • ste_installed
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 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
Please fix the following items
  • 4× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/ship-to-ecourier/index.php
    • > /wp-content/plugins/ship-to-ecourier/includes/Admin/index.php
    • > /wp-content/plugins/ship-to-ecourier/includes/index.php
    • > /wp-content/plugins/ship-to-ecourier/includes/Frontend/index.php
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/ship-to-ecourier/includes/Frontend/views/form-parcel-tracker.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr_e() in wp-content/plugins/ship-to-ecourier/includes/Admin/views/ste-booking-metabox-view.php:18
    • > PHP Notice
      Undefined variable: order_shipped in wp-content/plugins/ship-to-ecourier/includes/Admin/views/ste-booking-metabox-view.php on line 14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/ship-to-ecourier/includes/Admin/views/settings-view.php:11

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 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
7 plugin tags: ecourier-parcel, ecourier-booking, ecourier-parcel-booking, ship-to-ecourier, ecourier...

ship-to-ecourier/ship-to-ecourier.php 77% from 13 tests

The primary PHP file in "Ship To eCourier" version 1.1.1 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 175 characters long)
  • Domain Path: The domain path folder does not exist ("/languages")
  • Git Repository: Please do not include Git repositories in your plugin

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected14,631 lines of code in 46 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript41,84210,51010,764
PHP358011,5853,202
CSS25019384
Markdown1660181
JSON30099
SVG1001

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity18.33
▷ Minimum class complexity1.00
▷ Maximum class complexity68.00
Average method complexity3.06
▷ Minimum method complexity1.00
▷ Maximum method complexity36.00
Code structure
Namespaces6
Interfaces0
Traits0
Classes21
▷ Abstract classes00.00%
▷ Concrete classes21100.00%
▷ Final classes14.76%
Methods178
▷ Static methods2212.36%
▷ Public methods13978.09%
▷ Protected methods63.37%
▷ Private methods3318.54%
Functions10
▷ Named functions770.00%
▷ Anonymous functions330.00%
Constants11
▷ Global constants872.73%
▷ Class constants327.27%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/menu_icon.png2.13KB1.06KB▼ 50.18%