Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
It is recommended to fix the following installer errors
- The plugin cannot be installed
- > Warning in wp-content/plugins/payment-gateway-payfabric/freemius/require.php+16
require_once(wp-content/plugins/payment-gateway-payfabric/freemius/includes/fs-html-escaping-functions.php): failed to open stream: No such file or directory
Server metrics [RAM: ▲0.00MB] [CPU: ▼4.15ms] Passed 4 tests
An overview of server-side resources used by Payment Gateway for PayFabric
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.46 ▲0.00 | 34.71 ▼5.95 |
Dashboard /wp-admin | 3.31 ▲0.00 | 44.97 ▼2.97 |
Posts /wp-admin/edit.php | 3.36 ▲0.00 | 47.63 ▼1.54 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.00 | 91.46 ▼6.15 |
Media Library /wp-admin/upload.php | 3.23 ▲0.00 | 32.39 ▼1.08 |
Server storage [IO: ▲2.94MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
This plugin installed successfully
Filesystem: 169 new files
Database: no new tables, 8 new options
New WordPress options |
---|
fs_active_plugins |
fs_debug_mode |
widget_recent-posts |
can_compress_scripts |
theysaidso_admin_options |
widget_theysaidso_widget |
widget_recent-comments |
db_upgraded |
Browser metrics Passed 4 tests
Checking browser requirements for Payment Gateway for PayFabric
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,825 ▲90 | 13.38 ▼1.29 | 6.13 ▲4.36 | 39.64 ▼12.12 |
Dashboard /wp-admin | 2,209 ▲21 | 5.90 ▲0.09 | 99.22 ▼12.81 | 38.55 ▼7.24 |
Posts /wp-admin/edit.php | 2,089 ▼3 | 1.99 ▼0.05 | 39.23 ▲0.76 | 35.27 ▼9.72 |
Add New Post /wp-admin/post-new.php | 1,543 ▲23 | 18.12 ▼5.12 | 611.10 ▼59.31 | 62.10 ▲13.44 |
Media Library /wp-admin/upload.php | 1,391 ▲3 | 4.21 ▲0.07 | 101.05 ▼9.81 | 42.74 ▼3.70 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
- This plugin did not uninstall successfully, leaving 8 options in the database
- fs_debug_mode
- fs_active_plugins
- widget_theysaidso_widget
- widget_recent-posts
- can_compress_scripts
- widget_recent-comments
- theysaidso_admin_options
- db_upgraded
Smoke tests 75% 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 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
- 2× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Class 'WC_Payment_Token_CC' not found in wp-content/plugins/payment-gateway-payfabric/class-wc-payment-token-payfabric.php:8
- > PHP Fatal error
Uncaught Error: Class 'WC_Payment_Gateway_CC' not found in wp-content/plugins/payment-gateway-payfabric/class-wc-gateway-payfabric.php:8
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found
Optimizations
Plugin configuration 97% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need to be fixed:
- Contributors: Plugin contributors field is missing
payment-gateway-payfabric/payment-gateway-payfabric.php Passed 13 tests
Analyzing the main PHP file in "Payment Gateway for PayFabric" version 1.0.13
44 characters long description:
A WooCommerce payment gateway for PayFabric.
Code Analysis 97% from 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
Success! There were no dangerous files found in this plugin31,935 lines of code in 125 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 111 | 7,506 | 16,532 | 31,730 |
JavaScript | 3 | 34 | 59 | 194 |
CSS | 11 | 0 | 0 | 11 |
PHP code 50% from 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
It is recommended to fix the following
- Class cyclomatic complexity has to be reduced to less than 1000 (currently 3,073)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.63 |
Average class complexity | 87.94 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 3,073.00 |
Average method complexity | 4.62 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 94.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 49 | |
▷ Abstract classes | 2 | 4.08% |
▷ Concrete classes | 47 | 95.92% |
▷ Final classes | 0 | 0.00% |
Methods | 1,206 | |
▷ Static methods | 204 | 16.92% |
▷ Public methods | 831 | 68.91% |
▷ Protected methods | 26 | 2.16% |
▷ Private methods | 349 | 28.94% |
Functions | 97 | |
▷ Named functions | 97 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 132 | |
▷ Global constants | 98 | 74.24% |
▷ Class constants | 34 | 25.76% |
▷ Public constants | 34 | 100.00% |
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
5 PNG files occupy 0.05MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
freemius/assets/img/payfabric-payment-gateway.png | 11.47KB | 6.35KB | ▼ 44.60% |
freemius/assets/img/woocommerce-payfabric-payment-gateway.png | 11.47KB | 6.35KB | ▼ 44.60% |
freemius/assets/img/theme-icon.png | 10.97KB | 5.78KB | ▼ 47.37% |
assets/images/cards.png | 8.09KB | 3.33KB | ▼ 58.77% |
freemius/assets/img/plugin-icon.png | 9.16KB | 5.26KB | ▼ 42.58% |