10% express-shop

Code Review | Express Shop

WordPress plugin Express Shop scored10%from 54 tests.

About plugin

  • Plugin page: express-shop
  • Plugin version: 4.1.5
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0 or higher-6.3
  • WordPress version: 6.3.1
  • First release: Apr 12, 2017
  • Latest release: Oct 23, 2023
  • Number of updates: 66
  • Update frequency: every 36.2 days
  • Top authors: quantumcloud (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

10+ active /7,743 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
These installer errors require your attention
  • Install procedure had errors
    • > Notice in wp-content/plugins/express-shop/qcld-express-main.php+248
    Trying to access array offset on value of type bool

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

Server-side resources used by Express Shop
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.11 ▼0.34
Dashboard /wp-admin3.31 ▲0.0144.81 ▼2.48
Posts /wp-admin/edit.php3.36 ▲0.0144.08 ▼5.27
Add New Post /wp-admin/post-new.php5.89 ▲0.0180.86 ▼17.16
Media Library /wp-admin/upload.php3.23 ▲0.0034.13 ▼2.08
Addons /wp-admin/admin.php?page=qcld-express-wholesale-addon3.0023.43
Settings /wp-admin/admin.php?page=qcld-express-options3.0024.19
Opening Hours /wp-admin/admin.php?page=express-shop3.0021.45
Support /wp-admin/admin.php?page=qcpro-promo-page-express-shop3.0022.31

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Express Shop
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,891 ▲13013.26 ▼1.271.78 ▲0.1331.39 ▼8.35
Dashboard /wp-admin2,195 ▲145.55 ▼0.1283.46 ▼16.9140.40 ▼2.79
Posts /wp-admin/edit.php2,100 ▼01.97 ▼0.0535.38 ▼3.1033.33 ▼3.71
Add New Post /wp-admin/post-new.php1,526 ▼023.10 ▼0.32657.37 ▼37.6451.87 ▼2.70
Media Library /wp-admin/upload.php1,400 ▼34.18 ▲0.0295.12 ▼4.5842.91 ▼3.44
Addons /wp-admin/admin.php?page=qcld-express-wholesale-addon280.420.103.75
Settings /wp-admin/admin.php?page=qcld-express-options280.420.064.18
Opening Hours /wp-admin/admin.php?page=express-shop280.420.084.22
Support /wp-admin/admin.php?page=qcpro-promo-page-express-shop280.420.063.63

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • This plugin does not fully uninstall, leaving 10 options in the database
    • ot_media_post_ID
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • qcld_express_options
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • option_tree
    • option_tree_settings

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 17× PHP files perform the task of outputting text when accessed with GET requests (only 10 are shown):
    • > /wp-content/plugins/express-shop/qcld-express-min-max-qty.php
    • > /wp-content/plugins/express-shop/qcld-express-ajax.php
    • > /wp-content/plugins/express-shop/inc/option-tree/includes/ot-functions.php
    • > /wp-content/plugins/express-shop/inc/option-tree/includes/ot-functions-docs-page.php
    • > /wp-content/plugins/express-shop/inc/option-tree/includes/class-ot-cleanup.php
    • > /wp-content/plugins/express-shop/qcld-express-dynamic-discount-price.php
    • > /wp-content/plugins/express-shop/inc/option-tree/includes/class-ot-post-formats.php
    • > /wp-content/plugins/express-shop/inc/option-tree/includes/ot-functions-admin.php
    • > /wp-content/plugins/express-shop/inc/option-tree/includes/ot-functions-option-types.php
    • > /wp-content/plugins/express-shop/inc/option-tree/includes/ot-functions-settings-page.php
  • 9× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Notice
      Undefined variable: qcld_express_show_mode in wp-content/plugins/express-shop/templates/qcld-express-modal.php on line 4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/express-shop/qcld-express-assets.php:28
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/express-shop/inc/option-tree/assets/theme-mode/demo-theme-options.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/express-shop/qcld-express-framework.php:6
    • > PHP Notice
      Undefined variable: qcld_express_show_mode in wp-content/plugins/express-shop/templates/qcld-express-modal.php on line 7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/express-shop/class-qcld-free-plugin-upgrade-notice.php:34
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_enqueue_style() in wp-content/plugins/express-shop/templates/basic/template.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/express-shop/inc/option-tree/assets/theme-mode/demo-meta-boxes.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/express-shop/qc-support-promo-page/class-qc-support-promo-page.php:8

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There are user-side issues you should fix
    • > GET request to /wp-admin/admin.php?page=qcld-express-wholesale-addon
    • > Network (severe)
    wp-admin/admin.php?page=qcld-express-wholesale-addon - Failed to load resource: the server responded with a status of 403 (Forbidden)
    • > GET request to /wp-admin/admin.php?page=qcld-express-options
    • > Network (severe)
    wp-admin/admin.php?page=qcld-express-options - Failed to load resource: the server responded with a status of 403 (Forbidden)
    • > GET request to /wp-admin/admin.php?page=express-shop
    • > Network (severe)
    wp-admin/admin.php?page=express-shop - Failed to load resource: the server responded with a status of 403 (Forbidden)
    • > GET request to /wp-admin/admin.php?page=qcpro-promo-page-express-shop
    • > Network (severe)
    wp-admin/admin.php?page=qcpro-promo-page-express-shop - Failed to load resource: the server responded with a status of 403 (Forbidden)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
7 plugin tags: product table, music store, woocommerce, woocommerce category list, woocommerce product table...

express-shop/qcld-express-main.php 85% from 13 tests

"Express Shop" version 4.1.5's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Requires at least: Periods and digits should be used for the required version number (ex. "7.0" instead of "4.0 or higher")
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("express-shop.php" instead of "qcld-express-main.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
There were no executable files found in this plugin39,951 lines of code in 63 files:
LanguageFilesBlank linesComment linesLines of code
CSS1362345519,252
PHP303,9864,39412,927
JavaScript141,2902553,955
SVG5003,753
JSON10064

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.59
Average class complexity45.25
▷ Minimum class complexity7.00
▷ Maximum class complexity153.00
Average method complexity5.63
▷ Minimum method complexity1.00
▷ Maximum method complexity47.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods77
▷ Static methods22.60%
▷ Public methods7192.21%
▷ Protected methods00.00%
▷ Private methods67.79%
Functions232
▷ Named functions22797.84%
▷ Anonymous functions52.16%
Constants29
▷ Global constants29100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
72 PNG files occupy 1.71MB with 1.06MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
qc-support-promo-page/images/icon-pack/service-08.png2.54KB1.42KB▼ 44.28%
qc-support-promo-page/images/icon.png31.48KB11.39KB▼ 63.81%
qc-support-promo-page/images/premium-theme-simple-blog.png72.36KB21.20KB▼ 70.70%
inc/option-tree/assets/images/layout/dual-sidebar.png3.88KB2.09KB▼ 46.20%
inc/option-tree/assets/images/ot-select.png1.03KB0.14KB▼ 86.03%