90% woo-order-on-whatsapp

Code Review | Order on Mobile for Wocoommerce

WordPress plugin Order on Mobile for Wocoommerce scored90%from 54 tests.

About plugin

  • Plugin page: woo-order-on-what...
  • Plugin version: 2.3.2
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5-6.3
  • WordPress version: 6.3.1
  • First release: Oct 19, 2018
  • Latest release: Aug 29, 2023
  • Number of updates: 52
  • Update frequency: every 34.2 days
  • Top authors: evcode (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

5,000+ active /91,993 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼4.37ms] Passed 4 tests

Server-side resources used by Order on Mobile for Wocoommerce
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0341.98 ▲0.89
Dashboard /wp-admin3.34 ▼0.0148.58 ▼10.56
Posts /wp-admin/edit.php3.39 ▲0.0345.18 ▼0.72
Add New Post /wp-admin/post-new.php5.92 ▲0.0384.62 ▼6.82
Media Library /wp-admin/upload.php3.26 ▲0.0338.30 ▲0.61

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 26 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Order on Mobile for Wocoommerce
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲5314.72 ▲0.362.01 ▲0.3843.40 ▲2.66
Dashboard /wp-admin2,195 ▲175.64 ▼0.0786.94 ▼13.6438.27 ▼3.21
Posts /wp-admin/edit.php2,100 ▼32.15 ▲0.2035.98 ▲0.4035.54 ▼1.46
Add New Post /wp-admin/post-new.php1,531 ▲223.08 ▲0.14671.57 ▲37.5750.87 ▼4.24
Media Library /wp-admin/upload.php1,400 ▲34.23 ▲0.0798.47 ▼11.4740.47 ▼6.26

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
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP Passed 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
7 plugin tags: order, products, woocommerce mobile, woocommerce, woocommerce whatsapp...

woo-order-on-whatsapp/woo-order-on-whatsapp.php Passed 13 tests

"Order on Mobile for Wocoommerce" version 2.3.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
125 characters long description:
Receive orders requests direct on your phone from buttons on your woocommerce product page, cart page and after the checkout.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected792 lines of code in 20 files:
LanguageFilesBlank linesComment linesLines of code
PHP16167411704
CSS210555
JavaScript21033

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity4.33
▷ Minimum class complexity2.00
▷ Maximum class complexity7.00
Average method complexity1.74
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes116.67%
▷ Concrete classes583.33%
▷ Final classes120.00%
Methods29
▷ Static methods310.34%
▷ Public methods2689.66%
▷ Protected methods26.90%
▷ Private methods13.45%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
3 compressed PNG files occupy 0.00MB
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/img/whatsapp.png0.68KB0.63KB▼ 7.91%
assets/img/icon_btn.png0.79KB0.98KB0.00%
assets/img/whatsapp-logo (4).png0.59KB0.68KB0.00%