83% woocommerce-users-custom-meta-search

Code Review | WooCommerce Users Custom Meta Search

WordPress plugin WooCommerce Users Custom Meta Search scored83%from 54 tests.

About plugin

  • Plugin page: woocommerce-users...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0+
  • WordPress version: 6.3.1
  • First release: Aug 24, 2013
  • Latest release: Aug 30, 2013
  • Number of updates: 7
  • Update frequency: every 0.9 days
  • Top authors: corsonr (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

40+ active /2,958 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: ▼2.59ms] Passed 4 tests

This is a short check of server-side resources used by WooCommerce Users Custom Meta Search
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.75 ▲0.0246.17 ▲1.99
Dashboard /wp-admin3.59 ▲0.0256.17 ▼1.39
Posts /wp-admin/edit.php3.70 ▲0.0249.40 ▼4.26
Add New Post /wp-admin/post-new.php6.17 ▲0.0288.04 ▼6.70
Media Library /wp-admin/upload.php3.51 ▲0.0240.52 ▲2.76

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

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

Browser metrics Passed 4 tests

Checking browser requirements for WooCommerce Users Custom Meta Search
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.26 ▼0.491.81 ▼0.0346.50 ▲2.06
Dashboard /wp-admin2,189 ▲125.88 ▲0.3296.68 ▼4.7046.41 ▲7.72
Posts /wp-admin/edit.php2,100 ▼02.16 ▲0.1438.56 ▼2.7836.93 ▲0.19
Add New Post /wp-admin/post-new.php1,546 ▲1523.08 ▼0.18643.94 ▼87.6162.32 ▼3.66
Media Library /wp-admin/upload.php1,403 ▲34.19 ▼0.0199.41 ▼1.5544.41 ▼3.50

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

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
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: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/woocommerce-users-custom-meta-search/woocommerce-users-custom-meta-search.php:25

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need to be fixed:
  • Screenshots: Screenshot #1 (The plugin settings within WooCommerce settings) image missing
The official readme.txt might help

woocommerce-users-custom-meta-search/woocommerce-users-custom-meta-search.php 77% from 13 tests

Analyzing the main PHP file in "WooCommerce Users Custom Meta Search" version 1.0
Please take the time to fix the following:
  • Domain Path: The domain path should use only dashes and lowercase characters ("languages")
  • Text Domain: The text domain name should consist of only dashes and lowercase characters
  • Domain Path: The domain path must begin with a forward slash character ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin174 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PO File16512193
PHP1384981

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.75
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%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
1 PNG file occupies 0.07MB with 0.05MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png68.32KB21.31KB▼ 68.81%