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
This plugin's installer ran successfully
Server metrics [RAM: ▲0.35MB] [CPU: ▼6.88ms] Passed 4 tests
A check of server-side resources used by Lightning Paywall
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.79 ▲0.33 | 38.19 ▲0.04 |
Dashboard /wp-admin | 3.70 ▲0.35 | 48.42 ▼9.82 |
Posts /wp-admin/edit.php | 3.75 ▲0.39 | 48.62 ▼1.23 |
Add New Post /wp-admin/post-new.php | 6.26 ▲0.37 | 83.73 ▼16.50 |
Media Library /wp-admin/upload.php | 3.56 ▲0.33 | 38.60 ▲5.76 |
Settings /wp-admin/admin.php?page=lnpw_general_settings | 3.55 | 41.00 |
Invoices /wp-admin/admin.php?page=lnpw_invoices | 3.52 | 31.32 |
Server storage [IO: ▲1.48MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 45 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
widget_recent-posts |
widget_theysaidso_widget |
can_compress_scripts |
widget_recent-comments |
theysaidso_admin_options |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Lightning Paywall
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,938 ▲167 | 13.82 ▼0.61 | 5.28 ▲3.30 | 33.14 ▼6.25 |
Dashboard /wp-admin | 2,258 ▲73 | 5.05 ▼0.80 | 112.58 ▲13.37 | 44.04 ▼1.55 |
Posts /wp-admin/edit.php | 2,147 ▲58 | 2.18 ▲0.13 | 44.88 ▲3.45 | 39.50 ▲3.25 |
Add New Post /wp-admin/post-new.php | 6,399 ▲4,880 | 28.13 ▲4.74 | 901.47 ▲290.27 | 38.36 ▼11.51 |
Media Library /wp-admin/upload.php | 1,443 ▲55 | 4.30 ▲0.20 | 108.44 ▼9.27 | 45.02 ▼5.70 |
Settings /wp-admin/admin.php?page=lnpw_general_settings | 1,131 | 2.36 | 30.56 | 33.48 |
Invoices /wp-admin/admin.php?page=lnpw_invoices | 856 | 2.30 | 28.87 | 40.07 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
- Zombie WordPress options detected upon uninstall: 6 options
- db_upgraded
- theysaidso_admin_options
- widget_recent-posts
- can_compress_scripts
- widget_theysaidso_widget
- widget_recent-comments
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 0% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
- 1× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/lightning-paywall/admin/partials/page-invoices.php
- 9× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/lightning-paywall/admin/elementor/class-start-video-widget.php:4
- > PHP Fatal error
Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/lightning-paywall/admin/elementor/class-file-widget.php:4
- > PHP Fatal error
Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/lightning-paywall/admin/elementor/class-end-content-widget.php:4
- > PHP Fatal error
Uncaught Error: Class 'Lightning_Paywall_Public' not found in wp-content/plugins/lightning-paywall/public/partials/lnpw-pay-block.php:3
- > PHP Fatal error
Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/lightning-paywall/admin/elementor/class-start-content-widget.php:4
- > PHP Fatal error
Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/lightning-paywall/admin/elementor/class-pay-block-widget.php:4
- > PHP Fatal error
Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/lightning-paywall/admin/elementor/class-end-video-widget.php:4
- > PHP Fatal error
Uncaught Error: Call to undefined function get_option() in wp-content/plugins/lightning-paywall/admin/partials/page-general-settings.php:3
- > PHP Fatal error
Uncaught Error: Class 'Elementor\\Widget_Base' not found in wp-content/plugins/lightning-paywall/admin/elementor/class-store-widget.php:4
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 88% from 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Please fix the following attributes:
- Screenshots: Please describe screenshot #19 in lightning-paywall/assets to your readme.txt
- Tags: Please reduce the number of tags, currently 11 tag instead of maximum 10
lightning-paywall/lightning-paywall.php 92% from 13 tests
The main PHP script in "Lightning Paywall" version 1.2.2 is automatically included on every request by WordPress
The following require your attention:
- Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 187 characters long)
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected38,541 lines of code in 38 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JSON | 2 | 0 | 0 | 35,032 |
PHP | 22 | 487 | 644 | 2,135 |
JavaScript | 11 | 49 | 0 | 1,114 |
CSS | 2 | 21 | 0 | 185 |
SVG | 1 | 1 | 0 | 75 |
PHP code Passed 2 tests
An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.22 |
Average class complexity | 9.07 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 89.00 |
Average method complexity | 1.97 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 15.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 14 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 14 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 116 | |
▷ Static methods | 6 | 5.17% |
▷ Public methods | 88 | 75.86% |
▷ Protected methods | 14 | 12.07% |
▷ Private methods | 14 | 12.07% |
Functions | 3 | |
▷ Named functions | 3 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 4 | |
▷ Global constants | 1 | 25.00% |
▷ Class constants | 3 | 75.00% |
▷ Public constants | 3 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
public/img/preview.png | 20.39KB | 11.72KB | ▼ 42.50% |
public/img/file_preview.png | 5.54KB | 2.90KB | ▼ 47.71% |