Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully
Server metrics [RAM: ▲4.35MB] [CPU: ▲17.05ms] Passed 4 tests
An overview of server-side resources used by Leaky Paywall
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 7.89 ▲4.43 | 131.36 ▲88.93 |
Dashboard /wp-admin | 7.65 ▲4.31 | 71.42 ▲11.49 |
Posts /wp-admin/edit.php | 7.74 ▲4.39 | 63.87 ▲14.14 |
Add New Post /wp-admin/post-new.php | 10.26 ▲4.38 | 103.25 ▲6.74 |
Media Library /wp-admin/upload.php | 7.55 ▲4.32 | 68.97 ▲35.82 |
Upgrade /wp-admin/admin.php?page=leaky-paywall-upgrade | 7.52 | 51.94 |
Subscribers /wp-admin/admin.php?page=leaky-paywall-subscribers | 7.53 | 53.70 |
Settings /wp-admin/admin.php?page=issuem-leaky-paywall | 7.53 | 57.04 |
Transactions /wp-admin/edit.php?post_type=lp_transaction | 7.59 | 55.59 |
Insights /wp-admin/admin.php?page=leaky-paywall-insights | 7.54 | 53.98 |
Server storage [IO: ▲2.60MB] [DB: ▲0.02MB] Passed 3 tests
Filesystem and database footprint
This plugin was installed successfully
Filesystem: 380 new files
Database: no new tables, 7 new options
New WordPress options |
---|
widget_recent-comments |
theysaidso_admin_options |
db_upgraded |
widget_recent-posts |
last_zeen101_dot_com_leaky_rss_item |
can_compress_scripts |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
Leaky Paywall: an overview of browser usage
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,082 ▲335 | 13.35 ▼1.00 | 9.54 ▲7.72 | 42.23 ▼1.69 |
Dashboard /wp-admin | 2,347 ▲167 | 5.66 ▲0.04 | 94.86 ▼2.52 | 40.05 ▼6.85 |
Posts /wp-admin/edit.php | 2,196 ▲96 | 1.98 ▼0.04 | 34.24 ▼2.06 | 33.93 ▲2.13 |
Add New Post /wp-admin/post-new.php | 1,661 ▲135 | 22.15 ▼0.83 | 673.08 ▼17.17 | 62.56 ▲12.69 |
Media Library /wp-admin/upload.php | 1,495 ▲98 | 4.28 ▲0.10 | 100.68 ▼1.05 | 41.48 ▼5.26 |
Upgrade /wp-admin/admin.php?page=leaky-paywall-upgrade | 933 | 2.18 | 23.62 | 32.16 |
Subscribers /wp-admin/admin.php?page=leaky-paywall-subscribers | 1,483 | 1.80 | 29.95 | 31.70 |
Settings /wp-admin/admin.php?page=issuem-leaky-paywall | 1,146 | 2.03 | 26.16 | 32.54 |
Transactions /wp-admin/edit.php?post_type=lp_transaction | 1,158 | 1.94 | 30.32 | 29.49 |
Insights /wp-admin/admin.php?page=leaky-paywall-insights | 1,007 | 2.15 | 31.96 | 30.17 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.02MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
- Zombie WordPress options detected upon uninstall: 7 options
- widget_theysaidso_widget
- widget_recent-posts
- widget_recent-comments
- last_zeen101_dot_com_leaky_rss_item
- db_upgraded
- can_compress_scripts
- theysaidso_admin_options
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test
SRP 0% from 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
Please fix the following items
- 2× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/leaky-paywall/include/stripe/build.php
- > /wp-content/plugins/leaky-paywall/include/stripe/update_certs.php
- 252× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/leaky-paywall/include/admin/tools.php:3
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/leaky-paywall/include/stripe/lib/Terminal/Location.php:21
- > PHP Fatal error
Uncaught Error: Class 'Stripe_ApiResource' not found in wp-content/plugins/leaky-paywall/include/stripe/lib/Stripe/Transfer.php:3
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/leaky-paywall/include/stripe/lib/ApplicationFeeRefund.php:25
- > PHP Notice
Trying to access array offset on value of type null in wp-content/plugins/leaky-paywall/include/stripe/build.php on line 5
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\Service\\AbstractService' not found in wp-content/plugins/leaky-paywall/include/stripe/lib/Service/TransferService.php:7
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\Service\\AbstractService' not found in wp-content/plugins/leaky-paywall/include/stripe/lib/Service/CountrySpecService.php:7
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/leaky-paywall/include/stripe/lib/Token.php:46
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/leaky-paywall/include/stripe/lib/Coupon.php:32
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\Service\\AbstractService' not found in wp-content/plugins/leaky-paywall/include/stripe/lib/Service/DisputeService.php:7
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 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
10 plugin tags: metered, metered paywall, paid content, metered pay wall, membership...
leaky-paywall/leaky-paywall.php Passed 13 tests
"Leaky Paywall" version 4.20.5's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
127 characters long description:
The first and most flexible metered paywall for WordPress. Sell subscriptions without sacrificing search and social visibility.
Code Analysis 3% from 3 tests
File types 0% from 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
These items require your attention
- Do not distribute dangerous files with your plugin
- .crt - Security Certificate in Firefox, IE, Chrome, Safari
- ☣ wp-content/plugins/leaky-paywall/include/stripe/data/ca-certificates.crt
- ☣ wp-content/plugins/leaky-paywall/include/stripe/lib/data/ca-certificates.crt
- .crt - Security Certificate in Firefox, IE, Chrome, Safari
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 301 | 5,129 | 11,514 | 20,288 |
CSS | 5 | 215 | 40 | 3,353 |
PO File | 2 | 1,083 | 1,115 | 2,422 |
JavaScript | 15 | 344 | 155 | 1,572 |
Markdown | 4 | 639 | 0 | 952 |
YAML | 3 | 8 | 3 | 68 |
XML | 3 | 0 | 0 | 61 |
JSON | 1 | 0 | 0 | 37 |
make | 1 | 9 | 0 | 27 |
PHP code 50% from 2 tests
This is a short overview of cyclomatic complexity and code structure for this plugin
It is recommended to fix the following
- Cyclomatic complexity of methods has to be reduced to less than 100 (currently 106)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.32 |
Average class complexity | 5.83 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 190.00 |
Average method complexity | 2.34 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 106.00 |
Code structure | ||
---|---|---|
Namespaces | 23 | |
Interfaces | 8 | |
Traits | 7 | |
Classes | 268 | |
▷ Abstract classes | 16 | 5.97% |
▷ Concrete classes | 252 | 94.03% |
▷ Final classes | 0 | 0.00% |
Methods | 1,018 | |
▷ Static methods | 219 | 21.51% |
▷ Public methods | 931 | 91.45% |
▷ Protected methods | 41 | 4.03% |
▷ Private methods | 46 | 4.52% |
Functions | 158 | |
▷ Named functions | 153 | 96.84% |
▷ Anonymous functions | 5 | 3.16% |
Constants | 702 | |
▷ Global constants | 25 | 3.56% |
▷ Class constants | 677 | 96.44% |
▷ Public constants | 677 | 100.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
26 PNG files occupy 0.16MB with 0.05MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/ui-bg_glass_100_fdf5ce_1x400.png | 0.40KB | 0.16KB | ▼ 60.59% |
images/ui-icons_ffffff_256x240.png | 6.33KB | 4.18KB | ▼ 33.99% |
images/lock-icon.png | 1.22KB | 0.62KB | ▼ 49.00% |
images/ui-icons_ffd27a_256x240.png | 4.51KB | 4.18KB | ▼ 7.28% |
images/PP_logo_h_150x38.png | 2.60KB | 2.46KB | ▼ 5.37% |