Benchmarks
Plugin footprint 64% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲5.84MB] [CPU: ▲56.92ms] 50% from 4 tests
This is a short check of server-side resources used by Paid Memberships Pro - Content Restriction, User Registration, & Paid Subscriptions
It is recommended to improve the following
- RAM: You should keep total memory usage under 10MB (currently 12.21MB on /wp-admin/admin.php?page=pmpro-paymentsettings)
- Extra RAM: The extra memory usage must be under 5MB (currently 5.84MB on /wp-admin/admin.php?page=pmpro-advancedsettings)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 9.16 ▲5.69 | 106.26 ▲65.16 |
Dashboard /wp-admin | 9.22 ▲5.91 | 100.76 ▲48.45 |
Posts /wp-admin/edit.php | 9.27 ▲5.92 | 113.86 ▲71.81 |
Add New Post /wp-admin/post-new.php | 11.85 ▲5.96 | 144.57 ▲47.84 |
Media Library /wp-admin/upload.php | 9.07 ▲5.84 | 97.76 ▲66.22 |
Email Templates /wp-admin/admin.php?page=pmpro-emailtemplates | 9.28 | 91.13 |
Orders /wp-admin/admin.php?page=pmpro-orders | 9.39 | 86.99 |
Reports /wp-admin/admin.php?page=pmpro-reports | 9.26 | 123.46 |
User Fields /wp-admin/admin.php?page=pmpro-userfields | 9.27 | 83.77 |
Members /wp-admin/admin.php?page=pmpro-memberslist | 9.27 | 86.29 |
Setup Wizard /wp-admin/admin.php?page=pmpro-wizard | 9.06 | 83.00 |
Add Ons /wp-admin/admin.php?page=pmpro-addons | 10.08 | 100.92 |
Email Settings /wp-admin/admin.php?page=pmpro-emailsettings | 9.28 | 109.64 |
Payment Settings /wp-admin/admin.php?page=pmpro-paymentsettings | 12.21 | 142.95 |
Advanced Settings /wp-admin/admin.php?page=pmpro-advancedsettings | 9.33 | 102.52 |
Server storage [IO: ▲30.52MB] [DB: ▲0.28MB] 67% from 3 tests
How much does this plugin use your filesystem and database?
Just a few items left to fix
- Total filesystem usage should be limited to 25MB (currently using 30.52MB)
Filesystem: 1,279 new files
Database: 10 new tables, 17 new options
New tables |
---|
wp_pmpro_memberships_users |
wp_pmpro_membership_ordermeta |
wp_pmpro_membership_levelmeta |
wp_pmpro_discount_codes_levels |
wp_pmpro_memberships_pages |
wp_pmpro_membership_orders |
wp_pmpro_memberships_categories |
wp_pmpro_membership_levels |
wp_pmpro_discount_codes |
wp_pmpro_discount_codes_uses |
New WordPress options |
---|
wisdom_admin_emails |
wisdom_block_notice |
wisdom_collect_email |
wisdom_allow_tracking |
wisdom_notification_times |
pmpro_dismissed_wp_pointers |
widget_pmpro-member-login |
wisdom_last_track_time |
db_upgraded |
pmpro_views |
... |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Paid Memberships Pro - Content Restriction, User Registration, & Paid Subscriptions
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,920 ▲158 | 13.76 ▼0.95 | 1.74 ▼0.03 | 38.37 ▼6.83 |
Dashboard /wp-admin | 2,285 ▲111 | 5.07 ▼0.47 | 106.06 ▼2.13 | 45.89 ▼0.13 |
Posts /wp-admin/edit.php | 2,197 ▲97 | 2.16 ▲0.17 | 41.42 ▲1.57 | 41.23 ▲2.96 |
Add New Post /wp-admin/post-new.php | 1,820 ▲284 | 27.22 ▲4.05 | 696.47 ▲88.50 | 37.98 ▼7.73 |
Media Library /wp-admin/upload.php | 1,567 ▲167 | 4.60 ▲0.44 | 104.05 ▼1.53 | 45.60 ▼1.04 |
Email Templates /wp-admin/admin.php?page=pmpro-emailtemplates | 1,687 | 2.41 | 40.66 | 57.57 |
Orders /wp-admin/admin.php?page=pmpro-orders | 1,545 | 2.30 | 37.79 | 42.76 |
Reports /wp-admin/admin.php?page=pmpro-reports | 1,465 | 5.39 | 69.88 | 53.10 |
User Fields /wp-admin/admin.php?page=pmpro-userfields | 1,344 | 2.47 | 51.09 | 38.33 |
Members /wp-admin/admin.php?page=pmpro-memberslist | 1,479 | 2.39 | 38.10 | 42.98 |
Setup Wizard /wp-admin/admin.php?page=pmpro-wizard | 1,125 | 2.17 | 35.64 | 39.23 |
Add Ons /wp-admin/admin.php?page=pmpro-addons | 7,462 | 2.30 | 44.44 | 189.17 |
Email Settings /wp-admin/admin.php?page=pmpro-emailsettings | 1,135 | 2.42 | 95.53 | 110.37 |
Payment Settings /wp-admin/admin.php?page=pmpro-paymentsettings | 2,394 | 2.40 | 44.51 | 48.85 |
Advanced Settings /wp-admin/admin.php?page=pmpro-advancedsettings | 1,661 | 2.37 | 40.41 | 46.23 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.27MB] 50% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
- Zombie tables detected upon uninstall: 10 tables
- wp_pmpro_discount_codes
- wp_pmpro_membership_levelmeta
- wp_pmpro_discount_codes_levels
- wp_pmpro_membership_ordermeta
- wp_pmpro_memberships_users
- wp_pmpro_membership_orders
- wp_pmpro_membership_levels
- wp_pmpro_discount_codes_uses
- wp_pmpro_memberships_pages
- wp_pmpro_memberships_categories
- The uninstall procedure has failed, leaving 17 options in the database
- pmpro_visits
- widget_theysaidso_widget
- pmpro_views
- wisdom_last_track_time
- widget_pmpro-member-login
- pmpro_dismissed_wp_pointers
- widget_recent-comments
- pmpro_logins
- wisdom_allow_tracking
- wisdom_notification_times
- ...
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 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
- 24× GET requests to PHP files return non-empty strings (only 10 are shown):
- > /wp-content/plugins/paid-memberships-pro/blocks/account-page/block.php
- > /wp-content/plugins/paid-memberships-pro/blocks/login/block.php
- > /wp-content/plugins/paid-memberships-pro/classes/class-deny-network-activation.php
- > /wp-content/plugins/paid-memberships-pro/adminpages/admin_footer.php
- > /wp-content/plugins/paid-memberships-pro/blocks/account-profile-section/block.php
- > /wp-content/plugins/paid-memberships-pro/blocks/billing-page/block.php
- > /wp-content/plugins/paid-memberships-pro/scheduled/expirationwarnings.php
- > /wp-content/plugins/paid-memberships-pro/scheduled/expirememberships.php
- > /wp-content/plugins/paid-memberships-pro/scheduled/trialendingwarnings.php
- > /wp-content/plugins/paid-memberships-pro/blocks/account-invoices-section/block.php
- 497× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'Braintree\\Base' not found in wp-content/plugins/paid-memberships-pro/includes/lib/Braintree/lib/Braintree/CreditCard.php:31
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\Exception\\ApiErrorException' not found in wp-content/plugins/paid-memberships-pro/includes/lib/Stripe/lib/Exception/OAuth/OAuthErrorException.php:9
- > PHP Fatal error
Uncaught Error: Call to undefined function pmpro_getOption() in wp-content/plugins/paid-memberships-pro/includes/content.php:275
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/paid-memberships-pro/includes/lib/Stripe/lib/FinancialConnections/AccountOwner.php:17
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/paid-memberships-pro/adminpages/emailsettings.php:5
- > PHP Fatal error
Uncaught Error: Class 'Braintree\\Exception' not found in wp-content/plugins/paid-memberships-pro/includes/lib/Braintree/lib/Braintree/Exception/InvalidChallenge.php:6
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/paid-memberships-pro/includes/lib/Stripe/lib/FinancialConnections/Session.php:21
- > PHP Fatal error
Uncaught Error: Class 'Braintree\\Instance' not found in wp-content/plugins/paid-memberships-pro/includes/lib/Braintree/lib/Braintree/Transaction/AmexExpressCheckoutCardDetails.php:31
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/paid-memberships-pro/includes/lib/Stripe/lib/Treasury/OutboundTransfer.php:39
- > PHP Fatal error
Uncaught Error: Class 'Braintree\\Http' not found in wp-content/plugins/paid-memberships-pro/includes/lib/Braintree/lib/Braintree/GraphQL.php:10
- > 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)
Everything seems fine on the user side
Optimizations
Plugin configuration 97% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Please fix the following attributes:
- Tags: Please delete some tags, you are using 16 tag instead of maximum 10
paid-memberships-pro/paid-memberships-pro.php Passed 13 tests
"Paid Memberships Pro - Content Restriction, User Registration, & Paid Subscriptions" version 2.12.4's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
86 characters long description:
The most complete member management and membership subscriptions plugin for WordPress.
Code Analysis 3% from 3 tests
File types 0% from 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Please fix the following items
- Do not include executable or dangerous files in your plugin
- .crt - Security Certificate in Firefox, IE, Chrome, Safari
- ☣ wp-content/plugins/paid-memberships-pro/includes/lib/Braintree/lib/ssl/api_braintreegateway_com.ca.crt
- ☣ wp-content/plugins/paid-memberships-pro/includes/lib/Stripe/data/ca-certificates.crt
- .crt - Security Certificate in Firefox, IE, Chrome, Safari
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PO File | 29 | 72,024 | 439,943 | 157,755 |
PHP | 671 | 12,407 | 29,632 | 66,122 |
JavaScript | 39 | 314 | 487 | 3,043 |
CSS | 7 | 453 | 135 | 2,868 |
HTML | 295 | 883 | 0 | 2,838 |
Markdown | 2 | 156 | 0 | 424 |
SQL | 1 | 30 | 51 | 162 |
Bourne Shell | 2 | 21 | 19 | 141 |
SVG | 3 | 0 | 0 | 3 |
PHP code 50% from 2 tests
An short overview of logical lines of code, cyclomatic complexity, and other code metrics
These items need your attention
- Method cyclomatic complexity should be reduced to less than 100 (currently 120)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.36 |
Average class complexity | 8.98 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 678.00 |
Average method complexity | 2.58 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 120.00 |
Code structure | ||
---|---|---|
Namespaces | 61 | |
Interfaces | 9 | |
Traits | 9 | |
Classes | 485 | |
▷ Abstract classes | 13 | 2.68% |
▷ Concrete classes | 472 | 97.32% |
▷ Final classes | 0 | 0.00% |
Methods | 2,503 | |
▷ Static methods | 822 | 32.84% |
▷ Public methods | 2,213 | 88.41% |
▷ Protected methods | 103 | 4.12% |
▷ Private methods | 187 | 7.47% |
Functions | 723 | |
▷ Named functions | 701 | 96.96% |
▷ Anonymous functions | 22 | 3.04% |
Constants | 1,781 | |
▷ Global constants | 27 | 1.52% |
▷ Class constants | 1,754 | 98.48% |
▷ Public constants | 1,754 | 100.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
107 PNG files occupy 2.07MB with 0.92MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/add-ons/pmpro-membership-maps.png | 15.09KB | 7.36KB | ▼ 51.26% |
images/add-ons/pmpro-donations.png | 14.73KB | 6.59KB | ▼ 55.27% |
images/add-ons/pmpro-sponsored-members.png | 20.64KB | 8.71KB | ▼ 57.82% |
images/add-ons/pmpro-payfast.png | 26.05KB | 10.88KB | ▼ 58.22% |
images/select2.png | 0.60KB | 0.99KB | 0.00% |