67% point-of-sale-pos-woocommerce

Code Review | Jovvie Point of Sale POS API for WooCommerce

WordPress plugin Jovvie Point of Sale POS API for WooCommerce scored67%from 54 tests.

About plugin

  • Plugin page: point-of-sale-pos...
  • Plugin version: 4.0.3
  • PHP version: 7.4.16
  • WordPress compatibility: 2.4.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Dec 31, 2018
  • Latest release: Nov 20, 2023
  • Number of updates: 111
  • Update frequency: every 18.1 days
  • Top authors: bizswoop (100%)

Code review

54 tests

User reviews

21 reviews

Install metrics

500+ active /37,024 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.60MB] [CPU: ▲2.49ms] Passed 4 tests

Server-side resources used by Jovvie Point of Sale POS API for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /4.08 ▲0.6147.22 ▲1.14
Dashboard /wp-admin3.90 ▲0.5955.67 ▼0.94
Posts /wp-admin/edit.php4.01 ▲0.6554.79 ▲6.42
Add New Post /wp-admin/post-new.php6.48 ▲0.59100.43 ▲12.81
Media Library /wp-admin/upload.php3.82 ▲0.5941.15 ▲3.34

Server storage [IO: ▲37.83MB] [DB: ▲0.00MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
It is recommended to fix the following issues
  • Try to limit filesystem usage to 25MB (currently using 37.83MB)
Filesystem: 691 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Jovvie Point of Sale POS API for WooCommerce
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,801 ▲3914.25 ▼0.011.54 ▼0.2242.65 ▼7.60
Dashboard /wp-admin2,209 ▲325.60 ▼0.1495.47 ▼17.8438.76 ▼4.00
Posts /wp-admin/edit.php2,114 ▲141.99 ▲0.0241.79 ▲4.6640.69 ▲7.46
Add New Post /wp-admin/post-new.php1,532 ▲523.30 ▼0.01599.32 ▼97.1950.23 ▼7.53
Media Library /wp-admin/upload.php1,411 ▲114.16 ▼0.0199.77 ▲0.6942.62 ▲0.47

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

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
The following issues need your attention
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/point-of-sale-pos-woocommerce/includes/Gateway/Stripe/api/build.php
    • > /wp-content/plugins/point-of-sale-pos-woocommerce/includes/Gateway/Stripe/api/update_certs.php
  • 278× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Interface 'Stripe\\StripeClientInterface' not found in wp-content/plugins/point-of-sale-pos-woocommerce/includes/Gateway/Stripe/api/lib/BaseStripeClient.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\Service\\AbstractService' not found in wp-content/plugins/point-of-sale-pos-woocommerce/includes/Gateway/Stripe/api/lib/Service/FileService.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'ZPOS\\Admin\\Setting\\InputBase' not found in wp-content/plugins/point-of-sale-pos-woocommerce/includes/Admin/Setting/Input/ColorPicker.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Puc_v4p11_Factory' not found in wp-content/plugins/point-of-sale-pos-woocommerce/plugin-update-checker/Puc/v4/Factory.php:4
    • > PHP Warning
      require_once(ABSPATH/wp-admin/includes/user.php): failed to open stream: No such file or directory in wp-content/plugins/point-of-sale-pos-woocommerce/includes/Admin/Tabs/Users/Access.php on line 9
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\Service\\AbstractService' not found in wp-content/plugins/point-of-sale-pos-woocommerce/includes/Gateway/Stripe/api/lib/Service/SkuService.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'ZPOS\\Admin\\Setting\\CoreBox' not found in wp-content/plugins/point-of-sale-pos-woocommerce/includes/Admin/Tabs/Users/Multiple.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\Service\\AbstractService' not found in wp-content/plugins/point-of-sale-pos-woocommerce/includes/Gateway/Stripe/api/lib/Service/RefundService.php:5
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/point-of-sale-pos-woocommerce/includes/Gateway/Stripe/api/build.php on line 5
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/point-of-sale-pos-woocommerce/includes/Gateway/Stripe/api/lib/ThreeDSecure.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 86% 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
Attributes that need to be fixed:
  • Tags: There are too many tags (43 tag instead of maximum 10)
The official readme.txt might help

point-of-sale-pos-woocommerce/index.php 77% from 13 tests

Analyzing the main PHP file in "Jovvie Point of Sale POS API for WooCommerce" version 4.0.3
Please take the time to fix the following:
  • Requires at least: The required version number must match the one declared in readme.txt ("4.0" instead of "2.4.0")
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("point-of-sale-pos-woocommerce.php" instead of "index.php")
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug

Code Analysis 5% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Please make sure to remedy the following
  • You should never include executable (binary) or otherwise dangerous files in your plugin
    • .crt - Security Certificate in Firefox, IE, Chrome, Safari
      • wp-content/plugins/point-of-sale-pos-woocommerce/includes/Gateway/Stripe/api/data/ca-certificates.crt
124,293 lines of code in 541 files:
LanguageFilesBlank linesComment linesLines of code
SVG6702050,407
PHP3844,87411,03726,233
CSS108,4431326,068
PO File548,2709,56020,097
Markdown474301,164
JSON680185
JavaScript13171378
XML10031
make19027
YAML1003

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity6.29
▷ Minimum class complexity1.00
▷ Maximum class complexity159.00
Average method complexity2.13
▷ Minimum method complexity1.00
▷ Maximum method complexity32.00
Code structure
Namespaces43
Interfaces7
Traits11
Classes353
▷ Abstract classes236.52%
▷ Concrete classes33093.48%
▷ Final classes00.00%
Methods1,717
▷ Static methods30617.82%
▷ Public methods1,41282.24%
▷ Protected methods20511.94%
▷ Private methods1005.82%
Functions112
▷ Named functions00.00%
▷ Anonymous functions112100.00%
Constants756
▷ Global constants50.66%
▷ Class constants75199.34%
▷ Public constants74999.73%

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
20 PNG files occupy 1.96MB with 1.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-11.png158.90KB53.07KB▼ 66.60%
assets/admin/bizswoop.png12.40KB6.43KB▼ 48.13%
assets/admin/logo.png10.89KB2.73KB▼ 74.96%
assets/screenshot-2.png51.77KB13.45KB▼ 74.02%
assets/quick-start/hero.png25.11KB25.85KB0.00%