Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors
Server metrics [RAM: ▲0.07MB] [CPU: ▼7.51ms] Passed 4 tests
A check of server-side resources used by zahls.ch Credit Cards, PostFinance and TWINT for WooCommerce
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.54 ▲0.08 | 40.45 ▲2.80 |
Dashboard /wp-admin | 3.38 ▲0.04 | 47.46 ▼12.29 |
Posts /wp-admin/edit.php | 3.50 ▲0.14 | 45.83 ▼2.66 |
Add New Post /wp-admin/post-new.php | 5.96 ▲0.08 | 80.39 ▼11.86 |
Media Library /wp-admin/upload.php | 3.31 ▲0.08 | 35.46 ▼3.24 |
Server storage [IO: ▲1.44MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
No storage issues were detected
Filesystem: 159 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-posts |
can_compress_scripts |
db_upgraded |
theysaidso_admin_options |
widget_recent-comments |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
Checking browser requirements for zahls.ch Credit Cards, PostFinance and TWINT for WooCommerce
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,789 ▲43 | 14.33 ▼0.03 | 1.73 ▲0.09 | 43.95 ▲0.92 |
Dashboard /wp-admin | 2,198 ▲21 | 5.65 ▲0.07 | 93.44 ▲9.44 | 42.61 ▲2.78 |
Posts /wp-admin/edit.php | 2,100 ▼0 | 2.02 ▲0.02 | 32.88 ▼3.68 | 33.83 ▼2.58 |
Add New Post /wp-admin/post-new.php | 1,526 ▼0 | 23.54 ▲0.13 | 684.36 ▲1.31 | 60.92 ▲3.22 |
Media Library /wp-admin/upload.php | 1,397 ▼0 | 4.27 ▲0.10 | 96.09 ▼5.12 | 42.90 ▼2.11 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
- Zombie WordPress options detected upon uninstall: 6 options
- widget_recent-comments
- db_upgraded
- can_compress_scripts
- widget_recent-posts
- theysaidso_admin_options
- widget_theysaidso_widget
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested
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 items
- 37× GET requests to PHP files return non-empty strings (only 10 are shown):
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/QrCodeDelete.php
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/PageGetAll.php
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/TransactionGetAll.php
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/TransactionGetOne.php
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/InvoiceGetOne.php
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/PaymentMethodGetAll.php
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/GatewayCreate.php
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/PaymentProviderGetAll.php
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/PageGetOne.php
- > /wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/examples/DesignDelete.php
- 32× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'Zahls\\Models\\Request\\Transaction' not found in wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/lib/Zahls/Models/Response/Transaction.php:13
- > PHP Fatal error
Uncaught Error: Class 'Zahls\\Models\\Base' not found in wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/lib/Zahls/Models/Request/PaymentMethod.php:10
- > PHP Fatal error
Uncaught Error: Class 'Zahls\\Models\\Base' not found in wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/lib/Zahls/Models/Request/Invoice.php:9
- > PHP Fatal error
Uncaught Error: Class 'Zahls\\Models\\Request\\QrCodeScan' not found in wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/lib/Zahls/Models/Response/QrCodeScan.php:5
- > PHP Fatal error
Uncaught Error: Class 'Zahls\\Models\\Request\\PaymentProvider' not found in wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/lib/Zahls/Models/Response/PaymentProvider.php:10
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/zahls-ch-payment-gateway/includes/settings-zahls.php:4
- > PHP Fatal error
Uncaught Error: Class 'Zahls\\Models\\Base' not found in wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/lib/Zahls/Models/Request/PaymentProvider.php:9
- > PHP Fatal error
Uncaught Error: Class 'Zahls\\Models\\Base' not found in wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/lib/Zahls/Models/Request/Payout.php:7
- > PHP Fatal error
Uncaught Error: Class 'Zahls\\Models\\Request\\QrCode' not found in wp-content/plugins/zahls-ch-payment-gateway/zahls-php-master/lib/Zahls/Models/Response/QrCode.php:5
- > PHP Fatal error
Uncaught Error: Class 'Automattic\\WooCommerce\\Blocks\\Payments\\Integrations\\AbstractPaymentMethodType' not found in wp-content/plugins/zahls-ch-payment-gateway/includes/blocks-checkout.php:7
- > 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 93% from 29 tests
readme.txt 94% from 16 tests
You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
- Tags: You are using too many tags: 32 tag instead of maximum 10
zahls-ch-payment-gateway/woo-zahls-gateway.php 92% from 13 tests
The primary PHP file in "zahls.ch Credit Cards, PostFinance and TWINT for WooCommerce" version 2.0.2 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("zahls-ch-payment-gateway.php" instead of "woo-zahls-gateway.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
There were no executable files found in this plugin6,969 lines of code in 151 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 79 | 1,129 | 2,564 | 4,097 |
SVG | 70 | 10 | 47 | 2,788 |
Markdown | 1 | 17 | 0 | 59 |
JSON | 1 | 0 | 0 | 25 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.16 |
Average class complexity | 5.68 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 37.00 |
Average method complexity | 1.41 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 16.00 |
Code structure | ||
---|---|---|
Namespaces | 9 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 41 | |
▷ Abstract classes | 2 | 4.88% |
▷ Concrete classes | 39 | 95.12% |
▷ Final classes | 1 | 2.56% |
Methods | 450 | |
▷ Static methods | 7 | 1.56% |
▷ Public methods | 433 | 96.22% |
▷ Protected methods | 7 | 1.56% |
▷ Private methods | 10 | 2.22% |
Functions | 44 | |
▷ Named functions | 4 | 9.09% |
▷ Anonymous functions | 40 | 90.91% |
Constants | 41 | |
▷ Global constants | 5 | 12.20% |
▷ Class constants | 36 | 87.80% |
▷ Public constants | 36 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 PNG file occupies 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
zahls-php-master/examples/zahls-logo.png | 10.55KB | 6.51KB | ▼ 38.30% |