78% saleassist

Code Review | SaleAssist Live Video Engagements

WordPress plugin SaleAssist Live Video Engagements scored 78% from 54 tests.

About plugin

  • Plugin page: saleassist
  • Plugin version: 2.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-6.1.1
  • WordPress version: 6.3.1
  • First release: Apr 6, 2022
  • Latest release: Mar 23, 2023
  • Number of updates: 15
  • Update frequency: every 23.5 days
  • Top authors: saleassist (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 2,463 total downloads

Benchmarks

Plugin footprint 83% 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 gracefully, with no errors

Server metrics [RAM: ▲0.04MB] [CPU: ▼3.13ms] Passed 4 tests

A check of server-side resources used by SaleAssist Live Video Engagements
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0340.97 ▼0.60
Dashboard /wp-admin3.35 ▲0.0547.56 ▼4.65
Posts /wp-admin/edit.php3.39 ▲0.0450.84 ▲4.07
Add New Post /wp-admin/post-new.php5.92 ▲0.0484.22 ▼11.13
Media Library /wp-admin/upload.php3.27 ▲0.0439.48 ▲3.88

Server storage [IO: ▲3.76MB] [DB: ▲0.01MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 69 new files
Database: 2 new tables, 11 new options
New tables
wp_saleassist_btn
wp_saleassist
New WordPress options
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
saleassist_api_key
saleassist_db_version
db_upgraded
saleassist_secret_key
widget_recent-comments
theysaidso_admin_options
saleassist_data
...

Browser metrics Passed 4 tests

An overview of browser requirements for SaleAssist Live Video Engagements
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,075 ▲34017.81 ▲3.39332.02 ▲330.1470.64 ▲25.18
Dashboard /wp-admin2,345 ▲1545.97 ▲1.10105.59 ▼12.5397.69 ▲50.86
Posts /wp-admin/edit.php2,106 ▲171.97 ▼0.0937.54 ▲3.0544.41 ▲9.87
Add New Post /wp-admin/post-new.php1,524 ▼1223.16 ▼0.11763.05 ▲67.4754.93 ▼4.41
Media Library /wp-admin/upload.php1,402 ▲144.18 ▲0.01108.08 ▲10.0584.14 ▲37.45

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 50% 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 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
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/saleassist/saleassist.php
  • 31× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/saleassist/views/notice.php on line 96
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/saleassist/views/notice.php on line 92
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/saleassist/views/notice.php on line 104
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/saleassist/views/notice.php on line 135
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_url() in wp-content/plugins/saleassist/views/config.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'Saleassist' not found in wp-content/plugins/saleassist/wrapper.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/saleassist/class.saleassist-widget.php:5
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/saleassist/views/notice.php on line 108
    • > PHP Notice
      Undefined variable: type in wp-content/plugins/saleassist/views/notice.php on line 41
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/saleassist/views/predefined.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
  • Screenshots: Please add descriptions for these screenshots #1, #2, #2, #4, #5, #6, #7, #8, #9 in saleassist/assets to your readme.txt
  • Tags: Please delete some tags, you are using 11 tag instead of maximum 10
You can take inspiration from this readme.txt

saleassist/saleassist.php 92% from 13 tests

The entry point to "SaleAssist Live Video Engagements" version 2.0.0 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 494 characters long)

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
Good job! No executable or dangerous file extensions detected24,842 lines of code in 38 files:
LanguageFilesBlank linesComment linesLines of code
CSS101,6208713,694
JavaScript102,1091,8568,885
PHP183324012,263

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity47.00
▷ Minimum class complexity7.00
▷ Maximum class complexity93.00
Average method complexity3.22
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods83
▷ Static methods7792.77%
▷ Public methods8096.39%
▷ Protected methods00.00%
▷ Private methods33.61%
Functions19
▷ Named functions19100.00%
▷ Anonymous functions00.00%
Constants18
▷ Global constants1372.22%
▷ Class constants527.78%
▷ Public constants5100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
13 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/icon.png0.70KB0.60KB▼ 14.33%
assets/colorpicker/images/custom_hsb_s.png1.14KB0.89KB▼ 21.75%
_inc/img/logo-a-2x.png2.74KB1.24KB▼ 54.84%
assets/colorpicker/images/custom_rgb_b.png0.98KB0.74KB▼ 25.00%
assets/colorpicker/images/custom_hsb_b.png1.07KB0.82KB▼ 23.61%