10% woocommerce-coming-soon

Code Review | WooCommerce Coming Soon

WordPress plugin WooCommerce Coming Soon scored10%from 54 tests.

About plugin

  • Plugin page: woocommerce-comin...
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2-4.2.2
  • WordPress version: 6.3.1
  • First release: Mar 23, 2014
  • Latest release: Jul 9, 2015
  • Number of updates: 8
  • Update frequency: every 59.1 days
  • Top authors: sebd86 (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

200+ active /7,369 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
You still need to fix the following installer errors
  • Install procedure had errors
    • > Warning in wp-content/plugins/woocommerce-coming-soon/woocommerce-coming-soon.php+259
    Use of undefined constant WOOCOMMERCE_VERSION - assumed 'WOOCOMMERCE_VERSION' (this will throw an Error in a future version of PHP)

Server metrics [RAM: ▼1.96MB] [CPU: ▼88.11ms] Passed 4 tests

A check of server-side resources used by WooCommerce Coming Soon
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.4411.36 ▼56.41
Dashboard /wp-admin2.05 ▼1.2620.10 ▼75.87
Posts /wp-admin/edit.php2.05 ▼1.3112.58 ▼86.61
Add New Post /wp-admin/post-new.php2.05 ▼3.8415.48 ▼133.54
Media Library /wp-admin/upload.php2.05 ▼1.1811.94 ▼50.41

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

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

Browser metrics Passed 4 tests

Checking browser requirements for WooCommerce Coming Soon
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /1,452 ▼1,30911.41 ▼2.894.17 ▲0.2870.94 ▲3.13
Dashboard /wp-admin845 ▼1,3431.38 ▼3.5525.46 ▼171.9044.37 ▼43.42
Posts /wp-admin/edit.php856 ▼1,2331.53 ▼0.4612.73 ▼60.0138.54 ▼34.43
Add New Post /wp-admin/post-new.php582 ▼7821.73 ▼15.6932.75 ▼947.350.48 ▼80.52
Media Library /wp-admin/upload.php741 ▼6441.73 ▼2.4835.33 ▼152.7544.15 ▼53.38

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin cannot be uninstalled
    • > Warning in wp-content/plugins/woocommerce-coming-soon/woocommerce-coming-soon.php+259
    Use of undefined constant WOOCOMMERCE_VERSION - assumed 'WOOCOMMERCE_VERSION' (this will throw an Error in a future version of PHP)
  • This plugin does not fully uninstall, leaving 7 options in the database
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • recovery_mode_email_last_sent
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 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
The SRP test was a success

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 86% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need your attention:
  • Screenshots: These screenshots do not have images: #1 (Product Meta Data), #2 (Single Product Page)
You can take inspiration from this readme.txt

woocommerce-coming-soon/woocommerce-coming-soon.php 77% from 13 tests

Analyzing the main PHP file in "WooCommerce Coming Soon" version 1.0.1
You should first fix the following items:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Domain Path: The domain path should use only dashes and lowercase characters ("languages")
  • 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 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin215 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP776337215

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity7.00
▷ Minimum class complexity2.00
▷ Maximum class complexity12.00
Average method complexity1.63
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes150.00%
Methods19
▷ Static methods421.05%
▷ Public methods1894.74%
▷ Protected methods00.00%
▷ Private methods15.26%
Functions4
▷ Named functions4100.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
2 PNG files occupy 0.23MB with 0.13MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png12.74KB8.48KB▼ 33.39%
screenshot-2.png227.69KB59.45KB▼ 73.89%