89% shopp-lockdown

Code Review | Shopp Lockdown

WordPress plugin Shopp Lockdown scored 89% from 54 tests.

About plugin

  • Plugin page: shopp-lockdown
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.1.1
  • WordPress version: 5.8.1
  • First release: Mar 8, 2015
  • Latest release: Mar 8, 2015
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: adamsewell (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 440 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼139.34ms] Passed 4 tests

An overview of server-side resources used by Shopp Lockdown
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.87 ▲0.1549.97 ▲27.63
Dashboard /wp-admin3.09 ▲0.0443.61 ▼0.87
Posts /wp-admin/edit.php3.15 ▲0.0449.94 ▲5.07
Add New Post /wp-admin/post-new.php5.45 ▲0.0294.08 ▼565.92
Media Library /wp-admin/upload.php3.04 ▲0.0437.77 ▲4.37

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 5 new files
Database: no new tables, 1 new option
New WordPress options
shopp_lockout_options

Browser metrics Passed 4 tests

A check of browser resources used by Shopp Lockdown
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,715 ▲11915.77 ▲0.169.87 ▲1.6451.31 ▼3.20
Dashboard /wp-admin2,985 ▲545.88 ▼0.04142.84 ▼8.02109.28 ▼9.70
Posts /wp-admin/edit.php2,751 ▲122.69 ▼0.0069.80 ▼1.9195.38 ▲9.81
Add New Post /wp-admin/post-new.php1,691 ▲818.74 ▲0.39384.38 ▼22.92117.51 ▲7.14
Media Library /wp-admin/upload.php1,819 ▲125.02 ▼0.03165.79 ▲10.37120.37 ▼5.54

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin does not fully uninstall, leaving 1 option in the database
    • shopp_lockout_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
  • Screenshots: Screenshot #1 (This screen shot description corresponds to screenshot-1.(png|jpg|jpeg|gif). Note that the screenshot is taken from) image required
  • Plugin Name: Please specify the plugin name on the first line ( === shopp-lockdown === )
The official readme.txt is a good inspiration

shopp-lockdown/shopp-lockdown.php Passed 13 tests

The main PHP script in "Shopp Lockdown" version 1.0.0 is automatically included on every request by WordPress
106 characters long description:
Shopp Lockdown will watch failed credit card attempts and lock out repetitive failed transaction customer.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin154 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP14023154

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.28
Average class complexity18.00
▷ Minimum class complexity18.00
▷ Maximum class complexity18.00
Average method complexity2.55
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods00.00%
▷ Public methods11100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
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

Using a strong compression for your PNG files is a great way to speed-up your plugin
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
img/toolbox.png0.41KB0.44KB0.00%