89% wc-force-pass

Code Review | WC Force Pass

WordPress plugin WC Force Pass scored89%from 54 tests.

About plugin

  • Plugin page: wc-force-pass
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.5.2
  • WordPress version: 6.3.1
  • First release: Jun 1, 2016
  • Latest release: Jul 29, 2016
  • Number of updates: 5
  • Update frequency: every 11.4 days
  • Top authors: leobaiano (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

100+ active /1,346 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼4.21ms] Passed 4 tests

Server-side resources used by WC Force Pass
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.75 ▲0.0140.94 ▼9.01
Dashboard /wp-admin3.58 ▲0.0153.79 ▼1.79
Posts /wp-admin/edit.php3.69 ▲0.0150.90 ▼2.72
Add New Post /wp-admin/post-new.php6.16 ▲0.0195.50 ▼0.74
Media Library /wp-admin/upload.php3.50 ▲0.0135.58 ▼3.32

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for WC Force Pass
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,870 ▲10913.88 ▼0.769.51 ▲7.6340.14 ▼7.55
Dashboard /wp-admin2,195 ▲155.61 ▲0.0186.55 ▼6.3544.27 ▲1.23
Posts /wp-admin/edit.php2,100 ▼02.04 ▲0.0039.36 ▲1.6441.75 ▲3.12
Add New Post /wp-admin/post-new.php1,545 ▲1423.27 ▲0.02673.15 ▼2.9852.86 ▼7.95
Media Library /wp-admin/upload.php1,400 ▼34.28 ▲0.0297.74 ▼6.0542.02 ▼3.89

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests Passed 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 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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
4 plugin tags: password, register, woocommerce, store

wc-force-pass/wc-force-pass.php 85% from 13 tests

The main PHP file in "WC Force Pass" ver. 1.0.2 adds more information about the plugin and also serves as the entry point for this plugin
You should first fix the following items:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Domain Path: The domain path folder does not exist ("/languages/")

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 detected59 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP2156835
Markdown110017
JavaScript1007

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity3.00
▷ Minimum class complexity3.00
▷ Maximum class complexity3.00
Average method complexity1.33
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods6
▷ Static methods116.67%
▷ Public methods583.33%
▷ Protected methods00.00%
▷ Private methods116.67%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
PNG images were not found in this plugin