74% quasar-variable-attributes

Code Review | Quasar Variable Attributes

WordPress plugin Quasar Variable Attributes scored74%from 54 tests.

About plugin

  • Plugin page: quasar-variable-a...
  • Plugin version: 2.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-6.2
  • WordPress version: 6.3.1
  • First release: May 16, 2022
  • Latest release: Apr 4, 2023
  • Number of updates: 26
  • Update frequency: every 12.6 days
  • Top authors: nucleusgenius (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,205 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

Server metrics [RAM: ▲0.26MB] [CPU: ▼3.01ms] Passed 4 tests

Analyzing server-side resources used by Quasar Variable Attributes
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.73 ▲0.2650.65 ▼4.67
Dashboard /wp-admin3.55 ▲0.2556.92 ▲0.85
Posts /wp-admin/edit.php3.67 ▲0.3153.04 ▼1.86
Add New Post /wp-admin/post-new.php6.15 ▲0.2793.88 ▼6.35
Media Library /wp-admin/upload.php3.47 ▲0.2539.40 ▲1.93

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 66 new files
Database: 2 new tables, 6 new options
New tables
wp_quasar_attribute_option
wp_quasar_attribute_attr
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_recent-comments
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Quasar Variable Attributes
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,943 ▲18213.47 ▼1.0510.41 ▲8.7142.34 ▼2.30
Dashboard /wp-admin2,202 ▲255.62 ▼0.0895.61 ▼3.9963.16 ▲20.49
Posts /wp-admin/edit.php2,119 ▲222.00 ▼0.0333.97 ▼1.7132.70 ▼4.80
Add New Post /wp-admin/post-new.php1,545 ▲823.26 ▲5.15711.06 ▲29.4368.79 ▼12.56
Media Library /wp-admin/upload.php1,413 ▲134.23 ▲0.02102.30 ▼2.4168.34 ▲22.96

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • The uninstall procedure failed, leaving 2 tables in the database
    • wp_quasar_attribute_attr
    • wp_quasar_attribute_option
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting 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 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/quasar-variable-attributes/admin.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugins_url() in wp-content/plugins/quasar-variable-attributes/quasar-variable-attributes-main.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% 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
4 plugin tags: improved variable product attributes, variable product attributes, woocommerce form, woocommerce variable

quasar-variable-attributes/quasar-variable-attributes-main.php 92% from 13 tests

The main PHP file in "Quasar Variable Attributes" ver. 2.2 adds more information about the plugin and also serves as the entry point for this plugin
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("quasar-variable-attributes.php" instead of "quasar-variable-attributes-main.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin12,565 lines of code in 43 files:
LanguageFilesBlank linesComment linesLines of code
SVG1002,671
JavaScript53603822,207
CSS5325131,871
Sass1434341,768
LESS1434441,758
PHP23801491,744
PO File1234351479
Markdown127067

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions21
▷ Named functions21100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
3 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/img/strelka.png1.24KB1.21KB▼ 2.98%
assets/img/reload.png2.11KB1.03KB▼ 51.36%
assets/img/icon2.png0.42KB0.29KB▼ 29.58%