Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.27MB] [CPU: ▼3.49ms] Passed 4 tests
Server-side resources used by PW WooCommerce Gift Cards
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.76 ▲0.29 | 36.34 ▲2.66 |
Dashboard /wp-admin | 3.62 ▲0.28 | 46.77 ▼14.83 |
Posts /wp-admin/edit.php | 3.67 ▲0.31 | 49.38 ▲1.61 |
Add New Post /wp-admin/post-new.php | 6.14 ▲0.25 | 90.69 ▼3.41 |
Media Library /wp-admin/upload.php | 3.48 ▲0.25 | 36.66 ▲6.55 |
Server storage [IO: ▲3.53MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 92 new files
Database: 2 new tables, 6 new options
New tables |
---|
wp_pimwick_gift_card |
wp_pimwick_gift_card_activity |
New WordPress options |
---|
db_upgraded |
widget_theysaidso_widget |
theysaidso_admin_options |
widget_recent-posts |
widget_recent-comments |
can_compress_scripts |
Browser metrics Passed 4 tests
Checking browser requirements for PW WooCommerce Gift Cards
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,815 ▲53 | 14.19 ▼0.15 | 1.83 ▲0.24 | 36.39 ▲0.00 |
Dashboard /wp-admin | 2,195 ▲17 | 5.58 ▼0.13 | 95.07 ▼21.18 | 42.85 ▼4.85 |
Posts /wp-admin/edit.php | 2,100 ▼3 | 1.95 ▼0.02 | 40.09 ▼0.52 | 37.30 ▲0.01 |
Add New Post /wp-admin/post-new.php | 1,526 ▼0 | 23.27 ▼0.40 | 589.59 ▼134.02 | 55.03 ▲3.36 |
Media Library /wp-admin/upload.php | 1,403 ▲3 | 4.23 ▲0.03 | 96.45 ▼6.19 | 40.23 ▼4.62 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
- Zombie tables were found after uninstall: 2 tables
- wp_pimwick_gift_card_activity
- wp_pimwick_gift_card
- This plugin did not uninstall successfully, leaving 6 options in the database
- widget_recent-comments
- can_compress_scripts
- theysaidso_admin_options
- db_upgraded
- widget_recent-posts
- widget_theysaidso_widget
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means 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
Please fix the following items
- 5× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/pw-woocommerce-gift-cards/templates/woocommerce/emails/plain/customer-pw-gift-card.php:26
- > PHP Notice
Undefined variable: item_data in wp-content/plugins/pw-woocommerce-gift-cards/templates/woocommerce/emails/customer-pw-gift-card.php on line 21
- > PHP Notice
Undefined variable: email_heading in wp-content/plugins/pw-woocommerce-gift-cards/templates/woocommerce/emails/plain/customer-pw-gift-card.php on line 23
- > PHP Notice
Trying to get property 'preview' of non-object in wp-content/plugins/pw-woocommerce-gift-cards/templates/woocommerce/emails/customer-pw-gift-card.php on line 21
- > PHP Fatal error
Uncaught Error: Call to undefined function do_action() in wp-content/plugins/pw-woocommerce-gift-cards/templates/woocommerce/emails/customer-pw-gift-card.php:22
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
4 plugin tags: woocommerce, pimwick, gift certificates, gift cards
pw-woocommerce-gift-cards/pw-gift-cards.php 85% from 13 tests
This is the main PHP file of "PW WooCommerce Gift Cards" version 1.250, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("pw-woocommerce-gift-cards.php" instead of "pw-gift-cards.php")
- Requires at least: Required version must be the same as the one declared in readme.txt ("4.5" instead of "4.0")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin13,846 lines of code in 65 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PO File | 15 | 3,614 | 5,851 | 8,293 |
PHP | 39 | 1,189 | 702 | 4,378 |
CSS | 5 | 120 | 10 | 635 |
JavaScript | 5 | 97 | 13 | 524 |
XML | 1 | 0 | 0 | 16 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.42 |
Average class complexity | 45.31 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 166.00 |
Average method complexity | 3.62 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 30.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 13 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 13 | 100.00% |
▷ Final classes | 5 | 38.46% |
Methods | 218 | |
▷ Static methods | 11 | 5.05% |
▷ Public methods | 208 | 95.41% |
▷ Protected methods | 8 | 3.67% |
▷ Private methods | 2 | 0.92% |
Functions | 24 | |
▷ Named functions | 22 | 91.67% |
▷ Anonymous functions | 2 | 8.33% |
Constants | 2 | |
▷ Global constants | 2 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
4 PNG files occupy 0.29MB with 0.14MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/images/pw-gift-card.png | 161.65KB | 59.72KB | ▼ 63.05% |
assets/images/pro-design-example.png | 126.68KB | 41.10KB | ▼ 67.56% |
admin/assets/images/pimwick-icon-120x120.png | 3.89KB | 1.99KB | ▼ 48.71% |
admin/assets/images/pimwick.png | 2.74KB | 2.49KB | ▼ 9.09% |