89% enviaya-shipping-for-woocommerce

Code Review | EnvíaYa: Ship with all carriers (Rating, Booking and Tracking)

WordPress plugin EnvíaYa: Ship with all carriers (Rating, Booking and Tracking) scored89%from 54 tests.

About plugin

  • Plugin page: enviaya-shipping-...
  • Plugin version: 1.0.10
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0-6.0.2
  • WordPress version: 6.3.1
  • First release: Jun 6, 2022
  • Latest release: Oct 11, 2022
  • Number of updates: 17
  • Update frequency: every 9.2 days
  • Top authors: enviaya (100%)

Code review

54 tests

User reviews

1 review

Install metrics

300+ active /2,661 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.13MB] [CPU: ▼7.82ms] Passed 4 tests

An overview of server-side resources used by EnvíaYa: Ship with all carriers (Rating, Booking and Tracking)
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.61 ▲0.1444.61 ▼0.32
Dashboard /wp-admin3.45 ▲0.1050.95 ▼17.56
Posts /wp-admin/edit.php3.56 ▲0.2049.47 ▲1.58
Add New Post /wp-admin/post-new.php6.03 ▲0.1486.10 ▼14.98
Media Library /wp-admin/upload.php3.37 ▲0.1443.20 ▲8.11

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for EnvíaYa: Ship with all carriers (Rating, Booking and Tracking)
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲4314.34 ▼0.011.82 ▲0.0442.42 ▼4.89
Dashboard /wp-admin2,198 ▲185.63 ▲0.0185.84 ▼15.3040.18 ▼5.45
Posts /wp-admin/edit.php2,100 ▲212.02 ▲0.0340.91 ▲4.5752.16 ▲14.94
Add New Post /wp-admin/post-new.php1,526 ▼023.52 ▼0.13676.53 ▼15.7862.06 ▲6.59
Media Library /wp-admin/upload.php1,394 ▼64.29 ▲0.0596.92 ▼3.4143.54 ▼1.92

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% 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
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests Passed 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 Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Congratulations! This plugin passed the SRP 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 83% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Contributors: Plugin contributors field is missing
Please take inspiration from this readme.txt

enviaya-shipping-for-woocommerce/wc-enviaya-shipping.php 69% from 13 tests

"EnvíaYa: Ship with all carriers (Rating, Booking and Tracking)" version 1.0.10's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Requires at least: The required version number did not match the one declared in readme.txt ("5.0" instead of "6.0")
  • Description: Please don't use more than 140 characters for the plugin description (currently 148 characters long)
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("enviaya-shipping-for-woocommerce.php" instead of "wc-enviaya-shipping.php")
  • 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

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin7,180 lines of code in 24 files:
LanguageFilesBlank linesComment linesLines of code
PHP191,3805194,162
PO File21,33502,682
JavaScript11283249
CSS218187

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity36.94
▷ Minimum class complexity2.00
▷ Maximum class complexity243.00
Average method complexity3.23
▷ Minimum method complexity1.00
▷ Maximum method complexity25.00
Code structure
Namespaces8
Interfaces0
Traits0
Classes17
▷ Abstract classes317.65%
▷ Concrete classes1482.35%
▷ Final classes00.00%
Methods262
▷ Static methods20.76%
▷ Public methods16462.60%
▷ Protected methods9235.11%
▷ Private methods62.29%
Functions2
▷ Named functions00.00%
▷ Anonymous functions2100.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
18 PNG files occupy 0.22MB with 0.05MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/carriers/Ampm.png5.52KB4.21KB▼ 23.73%
assets/images/carriers/Treggo.png5.30KB3.88KB▼ 26.83%
assets/images/carriers/Tresguerras.png40.48KB18.13KB▼ 55.23%
assets/images/carriers/Pickit.png2.13KB2.10KB▼ 1.10%
assets/images/carriers/DHL.png1.38KB1.37KB0.50%