Benchmarks
Plugin footprint Passed 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully
Server metrics [RAM: ▲0.04MB] [CPU: ▼141.90ms] Passed 4 tests
This is a short check of server-side resources used by Content Lock
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.87 ▲0.15 | 29.90 ▲9.57 |
Dashboard /wp-admin | 3.10 ▲0.04 | 39.78 ▼4.37 |
Posts /wp-admin/edit.php | 3.15 ▲0.04 | 39.08 ▼5.89 |
Add New Post /wp-admin/post-new.php | 5.46 ▲0.03 | 93.97 ▼554.31 |
Media Library /wp-admin/upload.php | 3.04 ▲0.04 | 29.93 ▼3.04 |
Server storage [IO: ▲0.01MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 2 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
Content Lock: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,703 ▲107 | 15.88 ▼0.33 | 10.48 ▲1.46 | 51.67 ▼3.04 |
Dashboard /wp-admin | 2,973 ▲36 | 5.93 ▼0.05 | 136.71 ▼5.24 | 114.91 ▲0.04 |
Posts /wp-admin/edit.php | 2,739 ▼0 | 2.71 ▼0.01 | 64.58 ▲0.64 | 88.13 ▲3.87 |
Add New Post /wp-admin/post-new.php | 1,872 ▲372 | 18.93 ▲0.39 | 366.76 ▼10.19 | 107.21 ▲0.49 |
Media Library /wp-admin/upload.php | 1,807 ▼3 | 5.02 ▼0.02 | 145.84 ▲7.47 | 124.90 ▲7.92 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Uninstaller ran successfully
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested
SRP 50% from 2 tests
🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
- 1× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/content-lock/content-lock.php:29
- > PHP Fatal error
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)
No browser issues were found
Optimizations
Plugin configuration 97% 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:
- Donate link: Invalid url: ""
content-lock/content-lock.php Passed 13 tests
The main PHP script in "Content Lock" version 1.0 is automatically included on every request by WordPress
56 characters long description:
Show or hide your content with a wide variety of options
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 detected134 lines of code in 1 file:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 53 | 142 | 134 |
PHP code Passed 2 tests
Analyzing cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.27 |
Average class complexity | 16.00 |
▷ Minimum class complexity | 16.00 |
▷ Maximum class complexity | 16.00 |
Average method complexity | 1.94 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 4.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 16 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 13 | 81.25% |
▷ Protected methods | 3 | 18.75% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin