67% ltl-freight-quotes-ups-edition

Code Review | LTL Freight Quotes - TForce Edition

WordPress plugin LTL Freight Quotes - TForce Edition scored67%from 54 tests.

About plugin

  • Plugin page: ltl-freight-quote...
  • Plugin version: 3.5.1
  • PHP version: 7.4.16
  • WordPress compatibility: 6.4-6.4.1
  • WordPress version: 6.3.1
  • First release: May 12, 2017
  • Latest release: Nov 22, 2023
  • Number of updates: 65
  • Update frequency: every 36.9 days
  • Top authors: enituretechnology (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /4,221 total downloads

Benchmarks

Plugin footprint 65% 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.85MB] [CPU: ▼33.62ms] Passed 4 tests

An overview of server-side resources used by LTL Freight Quotes - TForce Edition
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.0939.52 ▼2.17
Dashboard /wp-admin3.11 ▼0.2426.76 ▼38.00
Posts /wp-admin/edit.php3.11 ▼0.2524.25 ▼24.88
Add New Post /wp-admin/post-new.php3.11 ▼2.7825.39 ▼67.30
Media Library /wp-admin/upload.php3.11 ▼0.1329.05 ▼4.28

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 56 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
can_compress_scripts
widget_recent-posts
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for LTL Freight Quotes - TForce Edition
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,912 ▲16513.74 ▼0.608.89 ▲7.0438.68 ▼7.15
Dashboard /wp-admin2,208 ▲315.64 ▼0.0194.29 ▼6.9842.65 ▼3.67
Posts /wp-admin/edit.php2,111 ▲112.09 ▲0.1139.38 ▲1.9734.96 ▼4.67
Add New Post /wp-admin/post-new.php1,539 ▲1323.03 ▼0.53578.23 ▼45.9250.89 ▼0.56
Media Library /wp-admin/upload.php1,416 ▲134.30 ▲0.1098.31 ▲4.5540.64 ▼1.24

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
You still need to fix the following
  • This plugin cannot be uninstalled
    • > Warning in wp-admin/includes/plugin.php+294
    opendir(wp-content/plugins/woocommerce): failed to open dir: No such file or directory
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • ups_freight_quotes_web_hook_plan_requests
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests 50% from 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 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
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/ltl-freight-quotes-ups-edition/logs/en-json-tree-view/en-jtv.php
  • 6× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ltl-freight-quotes-ups-edition/order/rates/order-rates.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ltl-freight-quotes-ups-edition/order/en-order-widget.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/ltl-freight-quotes-ups-edition/template/csv-export.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/ltl-freight-quotes-ups-edition/product/en-product-detail.php:24
    • > PHP Fatal error
      Uncaught Error: Class 'UPS_Curl_Request' not found in wp-content/plugins/ltl-freight-quotes-ups-edition/logs/en-logs.php:44
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/ltl-freight-quotes-ups-edition/order/en-order-export.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Please fix the following attributes:
  • Tags: There are too many tags (17 tag instead of maximum 10)
You can look at the official readme.txt

ltl-freight-quotes-ups-edition/ltl-freight-quotes-ups-edition.php 85% from 13 tests

"LTL Freight Quotes - TForce Edition" version 3.5.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
  • Requires at least: The required version number did not match the one declared in readme.txt ("6.2" instead of "6.4")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected9,453 lines of code in 46 files:
LanguageFilesBlank linesComment linesLines of code
PHP361,0741,1656,186
JavaScript64676512,205
CSS4158521,062

PHP code 50% from 2 tests

Analyzing cyclomatic complexity and code structure
The following items need your attention
  • Method cyclomatic complexity should be reduced to less than 100 (currently 112)
Cyclomatic complexity
Average complexity per logical line of code0.54
Average class complexity44.09
▷ Minimum class complexity1.00
▷ Maximum class complexity199.00
Average method complexity6.82
▷ Minimum method complexity1.00
▷ Maximum method complexity112.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes22
▷ Abstract classes00.00%
▷ Concrete classes22100.00%
▷ Final classes00.00%
Methods163
▷ Static methods10.61%
▷ Public methods163100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions49
▷ Named functions4897.96%
▷ Anonymous functions12.04%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
warehouse-dropship/wild/assets/images/delete.png3.49KB0.86KB▼ 75.41%
warehouse-dropship/wild/assets/images/edit.png3.09KB0.70KB▼ 77.43%