Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors
Server metrics [RAM: ▲0.54MB] [CPU: ▼4.71ms] Passed 4 tests
A check of server-side resources used by WP Stripe Cart
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.03 ▲0.57 | 45.35 ▲4.76 |
Dashboard /wp-admin | 3.88 ▲0.57 | 52.56 ▲3.29 |
Posts /wp-admin/edit.php | 3.93 ▲0.57 | 49.11 ▲3.96 |
Add New Post /wp-admin/post-new.php | 6.41 ▲0.52 | 80.80 ▼28.15 |
Media Library /wp-admin/upload.php | 3.74 ▲0.50 | 37.55 ▲2.08 |
Setting /wp-admin/admin.php?page=wp-stripe-cart-setting | 3.71 | 37.50 |
Order /wp-admin/admin.php?page=wp-stripe-cart | 3.79 | 41.00 |
Server storage [IO: ▲14.58MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
No storage issues were detected
Filesystem: 1,697 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-posts |
theysaidso_admin_options |
can_compress_scripts |
db_upgraded |
widget_theysaidso_widget |
widget_recent-comments |
Browser metrics Passed 4 tests
Checking browser requirements for WP Stripe Cart
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,911 ▲1,165 | 16.17 ▲1.81 | 173.92 ▲172.11 | 108.19 ▲66.43 |
Dashboard /wp-admin | 2,237 ▲46 | 4.87 ▼1.03 | 111.06 ▲7.05 | 42.12 ▲1.31 |
Posts /wp-admin/edit.php | 2,120 ▲31 | 2.02 ▼0.01 | 37.45 ▼1.07 | 31.59 ▼2.41 |
Add New Post /wp-admin/post-new.php | 1,539 ▼3 | 23.40 ▲5.24 | 621.32 ▼26.46 | 45.60 ▼8.92 |
Media Library /wp-admin/upload.php | 1,419 ▲28 | 4.21 ▼0.04 | 101.09 ▲5.21 | 41.63 ▼2.35 |
Setting /wp-admin/admin.php?page=wp-stripe-cart-setting | 2,373 | 2.20 | 25.43 | 39.09 |
Order /wp-admin/admin.php?page=wp-stripe-cart | 950 | 2.07 | 24.44 | 28.80 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
- The uninstall procedure has failed, leaving 6 options in the database
- db_upgraded
- widget_recent-comments
- theysaidso_admin_options
- can_compress_scripts
- widget_recent-posts
- widget_theysaidso_widget
Smoke tests 50% from 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 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
Please fix the following
- 3× PHP files output text when accessed directly:
- > /wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/build.php
- > /wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/update_certs.php
- > /wp-content/plugins/wp-stripe-cart/vendor/symfony/intl/Resources/bin/update-data.php
- 257× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\Exception\\ApiErrorException' not found in wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/lib/Exception/AuthenticationException.php:9
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/lib/Account.php:35
- > PHP Notice
Undefined variable: argv in wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/build.php on line 5
- > PHP Fatal error
Uncaught Error: Class 'Symfony\\Component\\Intl\\DateFormatter\\DateFormat\\HourTransformer' not found in wp-content/plugins/wp-stripe-cart/vendor/symfony/intl/DateFormatter/DateFormat/Hour2401Transformer.php:21
- > PHP Fatal error
Uncaught Error: Interface 'Stripe\\Exception\\ExceptionInterface' not found in wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/lib/Exception/OAuth/ExceptionInterface.php:8
- > PHP Fatal error
Uncaught Error: Interface 'Symfony\\Component\\Intl\\Exception\\ExceptionInterface' not found in wp-content/plugins/wp-stripe-cart/vendor/symfony/intl/Exception/BadMethodCallException.php:19
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/lib/Radar/ValueList.php:24
- > PHP Fatal error
Uncaught Error: Class 'Symfony\\Component\\Intl\\ResourceBundle' not found in wp-content/plugins/wp-stripe-cart/vendor/symfony/intl/Scripts.php:22
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\Service\\AbstractService' not found in wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/lib/Service/CustomerService.php:5
- > PHP Fatal error
Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/lib/SubscriptionItem.php:20
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
5 plugin tags: payment, credit card, google pay, apple pay, stripe
wp-stripe-cart/wp-stripe-cart.php Passed 13 tests
The main PHP script in "WP Stripe Cart" version 1.0.7 is automatically included on every request by WordPress
101 characters long description:
Simple cart for WordPress with STRIPE payment. Ideal for someone who wants to sell only few products.
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
Almost there! Just fix the following issues
- For security reasons, never distribute binary or executable files with your plugin
- .crt - Security Certificate in Firefox, IE, Chrome, Safari
- ☣ wp-content/plugins/wp-stripe-cart/vendor/stripe/stripe-php/data/ca-certificates.crt
- .crt - Security Certificate in Firefox, IE, Chrome, Safari
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JSON | 1,237 | 1 | 0 | 336,386 |
PHP | 312 | 3,125 | 12,153 | 12,717 |
Markdown | 7 | 657 | 0 | 1,018 |
PO File | 1 | 340 | 1,031 | 869 |
XML | 1 | 0 | 0 | 31 |
make | 1 | 9 | 0 | 27 |
SVG | 4 | 2 | 0 | 17 |
Bourne Again Shell | 1 | 2 | 0 | 11 |
JavaScript | 3 | 0 | 3 | 3 |
CSS | 2 | 0 | 0 | 2 |
PHP code 50% from 2 tests
An overview of cyclomatic complexity and code structure
It is recommended to fix the following
- Cyclomatic complexity of methods should be reduced to less than 100 (currently 247)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.26 |
Average class complexity | 5.41 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 285.00 |
Average method complexity | 2.19 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 247.00 |
Code structure | ||
---|---|---|
Namespaces | 37 | |
Interfaces | 12 | |
Traits | 8 | |
Classes | 276 | |
▷ Abstract classes | 19 | 6.88% |
▷ Concrete classes | 257 | 93.12% |
▷ Final classes | 10 | 3.89% |
Methods | 1,093 | |
▷ Static methods | 297 | 27.17% |
▷ Public methods | 910 | 83.26% |
▷ Protected methods | 94 | 8.60% |
▷ Private methods | 89 | 8.14% |
Functions | 42 | |
▷ Named functions | 19 | 45.24% |
▷ Anonymous functions | 23 | 54.76% |
Constants | 813 | |
▷ Global constants | 6 | 0.74% |
▷ Class constants | 807 | 99.26% |
▷ Public constants | 803 | 99.50% |
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 | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
asset/images/noimage.png | 4.91KB | 5.25KB | 0.00% |