83% order-on-mobile-for-woocommerce

Code Review | Order On Mobile for WooCommerce

WordPress plugin Order On Mobile for WooCommerce scored83%from 54 tests.

About plugin

  • Plugin page: order-on-mobile-f...
  • Plugin version: 2.2
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 7.8-6.3
  • WordPress version: 6.3.1
  • First release: Feb 17, 2020
  • Latest release: Jul 26, 2023
  • Number of updates: 34
  • Update frequency: every 37.0 days
  • Top authors: intolap (100%)

Code review

54 tests

User reviews

56 reviews

Install metrics

3,000+ active /24,669 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼10.90ms] Passed 4 tests

This is a short check of server-side resources used by Order On Mobile for WooCommerce
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0438.57 ▼1.77
Dashboard /wp-admin3.34 ▼0.0145.29 ▼16.58
Posts /wp-admin/edit.php3.39 ▲0.0352.99 ▲7.74
Add New Post /wp-admin/post-new.php5.94 ▲0.0582.17 ▼27.67
Media Library /wp-admin/upload.php3.26 ▲0.0335.41 ▲2.42

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 27 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
db_upgraded
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Order On Mobile for WooCommerce
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,972 ▲22613.59 ▼0.796.50 ▲4.6633.35 ▼9.81
Dashboard /wp-admin2,267 ▲825.83 ▲0.9195.67 ▼23.7442.19 ▼7.91
Posts /wp-admin/edit.php2,149 ▲602.15 ▲0.0241.38 ▲1.9939.81 ▲5.79
Add New Post /wp-admin/post-new.php1,564 ▲3117.60 ▼5.48621.70 ▼21.7145.29 ▼4.38
Media Library /wp-admin/upload.php1,449 ▲614.23 ▼0.0795.94 ▼12.2943.94 ▲3.13

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 does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/order-on-mobile-for-woocommerce/public/partials/woocommerce-order-on-whatsapp-public-display.php
    • > /wp-content/plugins/order-on-mobile-for-woocommerce/admin/partials/woocommerce-order-on-whatsapp-admin-display.php

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 79% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
  • Screenshots: Screenshot #7 ((PRO) WOOW Analytics - by country on top header (screenshot-7.png)) image not found
  • Screenshots: A description for screenshot #0 is required in order-on-mobile-for-woocommerce/assets to your readme.txt
You can take inspiration from this readme.txt

order-on-mobile-for-woocommerce/woocommerce-order-on-whatsapp.php 69% from 13 tests

"Order On Mobile for WooCommerce" version 2.2'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:
  • 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
  • Requires at least: The required version number must match the one declared in readme.txt ("6.2" instead of "7.8")
  • Description: Please don't use more than 140 characters for the plugin description (currently 161 characters long)
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("order-on-mobile-for-woocommerce.php" instead of "woocommerce-order-on-whatsapp.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 plugin621 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP12195559551
CSS28945
JavaScript275725

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.14
Average class complexity3.86
▷ Minimum class complexity1.00
▷ Maximum class complexity11.00
Average method complexity1.56
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods36
▷ Static methods822.22%
▷ Public methods3186.11%
▷ Protected methods00.00%
▷ Private methods513.89%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
1 PNG file occupies 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
public/img/whatsapp-button.png21.18KB7.75KB▼ 63.41%