84% benchmark-hero-quick-site-audit-for-your-ecommerce

Code Review | A Free SEO Site Audit For Woocommerce by Benchmark Hero

WordPress plugin A Free SEO Site Audit For Woocommerce by Benchmark Hero scored84%from 54 tests.

About plugin

  • Plugin page: benchmark-hero-qu...
  • Plugin version: 1.0.1
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.8
  • WordPress version: 6.3.1
  • First release: Oct 12, 2021
  • Latest release: Mar 10, 2022
  • Number of updates: 10
  • Update frequency: every 21.0 days
  • Top authors: storeya (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /727 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

Server-side resources used by A Free SEO Site Audit For Woocommerce by Benchmark Hero
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0332.91 ▼11.21
Dashboard /wp-admin3.33 ▼0.0145.43 ▼12.92
Posts /wp-admin/edit.php3.38 ▲0.0348.48 ▲1.16
Add New Post /wp-admin/post-new.php5.91 ▲0.0396.17 ▼5.85
Media Library /wp-admin/upload.php3.25 ▲0.0334.79 ▲2.55

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 13 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by A Free SEO Site Audit For Woocommerce by Benchmark Hero
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,812 ▲4113.60 ▼0.951.62 ▼0.3543.78 ▼0.04
Dashboard /wp-admin2,218 ▲334.83 ▼1.04107.93 ▲5.9339.51 ▲1.48
Posts /wp-admin/edit.php2,098 ▲92.01 ▼0.0040.68 ▲6.8634.73 ▲1.00
Add New Post /wp-admin/post-new.php1,554 ▲2618.20 ▼4.90611.85 ▼64.4656.37 ▼9.22
Media Library /wp-admin/upload.php1,400 ▲154.21 ▼0.0397.09 ▼9.8641.28 ▼6.67

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking 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 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/benchmark-hero-quick-site-audit-for-your-ecommerce/templates/admin-page.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/benchmark-hero-quick-site-audit-for-your-ecommerce/storeya-benchmark.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/benchmark-hero-quick-site-audit-for-your-ecommerce/src/storeya_benchmark_report_handler.php:7

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 93% 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
9 plugin tags: seo, marketing, adwords, benchmark, image optimization...

benchmark-hero-quick-site-audit-for-your-ecommerce/storeya-benchmark.php 85% from 13 tests

The principal PHP file in "A Free SEO Site Audit For Woocommerce by Benchmark Hero" v. 1.0.1 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("benchmark-hero-quick-site-audit-for-your-ecommerce.php" instead of "storeya-benchmark.php")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

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
Good job! No executable or dangerous file extensions detected1,797 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript32871551,307
PHP75912266
CSS1391224

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity3.80
▷ Minimum class complexity1.00
▷ Maximum class complexity8.00
Average method complexity1.58
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods24
▷ Static methods2395.83%
▷ Public methods24100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There are no PNG files in this plugin