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 successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.21MB] [CPU: ▼7.12ms] Passed 4 tests
Analyzing server-side resources used by The Travel Button®
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.67 ▲0.21 | 49.07 ▲8.23 |
Dashboard /wp-admin | 3.51 ▲0.21 | 47.65 ▼3.73 |
Posts /wp-admin/edit.php | 3.62 ▲0.27 | 49.86 ▼0.39 |
Add New Post /wp-admin/post-new.php | 6.11 ▲0.22 | 87.20 ▼14.55 |
Media Library /wp-admin/upload.php | 3.43 ▲0.20 | 37.02 ▼9.80 |
Server storage [IO: ▲3.10MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 57 new files
Database: 3 new tables, 6 new options
New tables |
---|
wp_wth_travel_button_buttons |
wp_wth_travel_button_styles |
wp_wth_travel_button_website_codes |
New WordPress options |
---|
can_compress_scripts |
widget_theysaidso_widget |
theysaidso_admin_options |
widget_recent-posts |
db_upgraded |
widget_recent-comments |
Browser metrics Passed 4 tests
This is an overview of browser requirements for The Travel Button®
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 4,685 ▲1,950 | 19.80 ▲5.00 | 18.89 ▲17.02 | 28.86 ▼14.85 |
Dashboard /wp-admin | 3,971 ▲1,782 | 7.76 ▲2.80 | 139.78 ▲12.52 | 48.63 ▲2.71 |
Posts /wp-admin/edit.php | 3,498 ▲1,406 | 4.08 ▲2.06 | 64.39 ▲30.22 | 37.31 ▲5.33 |
Add New Post /wp-admin/post-new.php | 2,872 ▲1,358 | 24.30 ▲6.63 | 733.88 ▲65.84 | 40.88 ▼11.05 |
Media Library /wp-admin/upload.php | 2,375 ▲993 | 5.43 ▲1.21 | 123.23 ▲26.18 | 40.36 ▼0.28 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- can_compress_scripts
- widget_recent-posts
- widget_recent-comments
- theysaidso_admin_options
- db_upgraded
- 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 everything seems fine, this is not 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
Please fix the following
- 13× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Notice
Undefined variable: table in wp-content/plugins/the-travel-button/admin/partials/load-db-record.php on line 14
- > PHP Notice
Undefined variable: current_styles in wp-content/plugins/the-travel-button/admin/partials/starting.php on line 13
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/the-travel-button/admin/partials/preferences.php:14
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/the-travel-button/admin/partials/new_button.php:13
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/the-travel-button/admin/partials/styles.php:13
- > PHP Notice
Undefined variable: current_buttons in wp-content/plugins/the-travel-button/admin/partials/starting.php on line 14
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/the-travel-button/admin/partials/buttons.php:13
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/the-travel-button/admin/partials/main.php:23
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/the-travel-button/admin/partials/new_style.php:13
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/the-travel-button/admin/partials/starting.php:18
- > PHP Notice
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
9 plugin tags: restaurant, tourism, activities, hotel, marketing...
the-travel-button/the-travel-button.php Passed 13 tests
"The Travel Button®" version 1.0.6's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
139 characters long description:
Monetize your travel content with your very own travel search engine. Help your audience plan their trips with customizable travel buttons.
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
Everything looks great! No dangerous files found in this plugin26,789 lines of code in 37 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 6 | 4,825 | 454 | 14,071 |
CSS | 6 | 98 | 3,044 | 10,220 |
PHP | 23 | 368 | 677 | 1,948 |
PO File | 2 | 260 | 230 | 550 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.37 |
Average class complexity | 19.10 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 93.00 |
Average method complexity | 4.23 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 38.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 10 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 10 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 56 | |
▷ Static methods | 4 | 7.14% |
▷ Public methods | 51 | 91.07% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 5 | 8.93% |
Functions | 4 | |
▷ Named functions | 4 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 2 | |
▷ Global constants | 2 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
9 PNG files occupy 1.37MB with 0.94MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
resources/screenshot-2.png | 173.60KB | 49.78KB | ▼ 71.33% |
resources/screenshot-8.png | 204.85KB | 59.42KB | ▼ 70.99% |
resources/screenshot-5.png | 140.90KB | 44.41KB | ▼ 68.48% |
resources/screenshot-3.png | 188.50KB | 64.10KB | ▼ 65.99% |
resources/screenshot-4.png | 191.52KB | 62.90KB | ▼ 67.16% |