Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully
Server metrics [RAM: ▲0.01MB] [CPU: ▲0.27ms] Passed 4 tests
Analyzing server-side resources used by Brankas Payment for WooCommerce
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 40.24 ▼1.69 |
Dashboard /wp-admin | 3.32 ▲0.01 | 54.05 ▲4.43 |
Posts /wp-admin/edit.php | 3.37 ▲0.01 | 43.51 ▲0.28 |
Add New Post /wp-admin/post-new.php | 5.90 ▲0.01 | 99.19 ▲3.06 |
Media Library /wp-admin/upload.php | 3.24 ▲0.01 | 31.30 ▼0.59 |
Server storage [IO: ▲1.07MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 19 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-comments |
widget_recent-posts |
widget_theysaidso_widget |
can_compress_scripts |
db_upgraded |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Checking browser requirements for Brankas Payment for WooCommerce
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,800 ▲54 | 13.22 ▼1.08 | 1.69 ▼0.10 | 43.11 ▼8.72 |
Dashboard /wp-admin | 2,209 ▲21 | 4.80 ▼1.05 | 99.68 ▼5.59 | 39.88 ▼0.19 |
Posts /wp-admin/edit.php | 2,089 ▼0 | 2.04 ▲0.03 | 35.73 ▲0.80 | 33.01 ▼2.26 |
Add New Post /wp-admin/post-new.php | 1,533 ▲14 | 23.03 ▼0.39 | 624.36 ▼3.55 | 74.11 ▲20.33 |
Media Library /wp-admin/upload.php | 1,388 ▼0 | 4.26 ▲0.05 | 98.38 ▼0.75 | 41.05 ▼2.87 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
- This plugin did not uninstall successfully, leaving 6 options in the database
- widget_recent-comments
- widget_recent-posts
- theysaidso_admin_options
- can_compress_scripts
- db_upgraded
- widget_theysaidso_widget
Smoke tests 75% 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 50% 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
Almost there! Just fix the following items
- 3× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Class 'WC_Payment_Gateway' not found in wp-content/plugins/brankas-payment-for-woocommerce/includes/class-wc-payment-gateway-brankas.php:13
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/brankas-payment-for-woocommerce/includes/brankas-checkout-validation.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/brankas-payment-for-woocommerce/includes/brankas-checkout-select-source-field.php:3
- > 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 93% 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
These attributes need to be fixed:
- Contributors: Plugin contributors field is missing
brankas-payment-for-woocommerce/brankas-payments-woocommerce.php 92% from 13 tests
The main file in "Brankas Payment for WooCommerce" v. 1.3.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
- Main file name: The principal plugin file should be the same as the plugin slug ("brankas-payment-for-woocommerce.php" instead of "brankas-payments-woocommerce.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin573 lines of code in 11 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 8 | 104 | 268 | 525 |
JavaScript | 1 | 2 | 0 | 23 |
CSS | 1 | 2 | 0 | 21 |
SVG | 1 | 0 | 0 | 4 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.27 |
Average class complexity | 15.00 |
▷ Minimum class complexity | 5.00 |
▷ Maximum class complexity | 25.00 |
Average method complexity | 2.04 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 5.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 26 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 14 | 53.85% |
▷ Protected methods | 12 | 46.15% |
▷ Private methods | 0 | 0.00% |
Functions | 12 | |
▷ Named functions | 11 | 91.67% |
▷ Anonymous functions | 1 | 8.33% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.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
7 PNG files occupy 1.03MB with 0.73MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/pics/Picture3.png | 89.63KB | 25.47KB | ▼ 71.58% |
assets/pics/Picture2.png | 247.33KB | 75.95KB | ▼ 69.29% |
assets/pics/Picture1.png | 155.90KB | 46.58KB | ▼ 70.12% |
assets/pics/Picture4.png | 140.26KB | 39.06KB | ▼ 72.15% |
assets/pics/Picture6.png | 158.74KB | 49.68KB | ▼ 68.70% |