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
Installer ran successfully
Server metrics [RAM: ▲0.55MB] [CPU: ▼6.66ms] 75% from 4 tests
An overview of server-side resources used by WP Page Templates
Please have a look at the following items
- CPU: Total CPU usage should be kept under 500.00ms (currently 1,766.36ms on /wp-admin/admin.php?page=wcpt_welcome_page)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.08 ▲0.62 | 41.68 ▲2.88 |
Dashboard /wp-admin | 3.92 ▲0.58 | 49.20 ▼11.40 |
Posts /wp-admin/edit.php | 3.98 ▲0.62 | 47.10 ▼2.39 |
Add New Post /wp-admin/post-new.php | 6.45 ▲0.56 | 92.55 ▼12.01 |
Media Library /wp-admin/upload.php | 3.68 ▲0.46 | 38.27 ▼0.83 |
WP Templates /wp-admin/admin.php?page=wcpt_welcome_page | 4.19 | 1,766.36 |
WP Templates /wp-admin/admin.php?page=wcpt_whats_new | 3.63 | 37.91 |
Freemius Debug [v.2.5.11] /wp-admin/admin.php?page=freemius | 4.04 | 35.82 |
Server storage [IO: ▲3.80MB] [DB: ▲0.07MB] Passed 3 tests
Filesystem and database footprint
This plugin installed successfully
Filesystem: 246 new files
Database: no new tables, 10 new options
New WordPress options |
---|
fs_active_plugins |
fs_accounts |
db_upgraded |
can_compress_scripts |
wcpt_welcome_redirect |
fs_debug_mode |
widget_recent-comments |
widget_recent-posts |
widget_theysaidso_widget |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Checking browser requirements for WP Page Templates
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,834 ▲63 | 13.73 ▼0.90 | 1.83 ▼0.14 | 33.12 ▼9.77 |
Dashboard /wp-admin | 2,243 ▲55 | 4.96 ▲0.07 | 102.79 ▼12.86 | 40.53 ▼3.87 |
Posts /wp-admin/edit.php | 2,126 ▲37 | 2.00 ▼0.05 | 37.93 ▲2.12 | 36.52 ▲5.21 |
Add New Post /wp-admin/post-new.php | 1,535 ▲21 | 23.56 ▲6.10 | 581.89 ▼84.59 | 48.43 ▼8.35 |
Media Library /wp-admin/upload.php | 1,425 ▲40 | 4.21 ▼0.01 | 97.70 ▼10.21 | 42.89 ▼3.50 |
WP Templates /wp-admin/admin.php?page=wcpt_welcome_page | 994 | 1.71 | 25.38 | 58.42 |
WP Templates /wp-admin/admin.php?page=wcpt_whats_new | 886 | 2.14 | 25.56 | 28.19 |
Freemius Debug [v.2.5.11] /wp-admin/admin.php?page=freemius | 1,094 | 1.71 | 22.98 | 27.74 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.07MB] 50% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
- Uninstall procedure had uncaught errors
- > Notice in wp-content/plugins/custom-page-templates-by-vegacorp/vendor/freemius/wordpress-sdk/includes/class-freemius.php+8515
Undefined property: stdClass::$plugins
- This plugin does not fully uninstall, leaving 10 options in the database
- widget_recent-comments
- widget_recent-posts
- wcpt_welcome_redirect
- fs_debug_mode
- fs_accounts
- fs_active_plugins
- widget_theysaidso_widget
- theysaidso_admin_options
- can_compress_scripts
- db_upgraded
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These errors were triggered by the plugin
- > GET request to /wp-admin/admin.php?page=wcpt_whats_new
- > Warning in wp-content/plugins/custom-page-templates-by-vegacorp/vendor/vegacorp/vg-freemius-sdk/index.php+164
include(wp-content/plugins/custom-page-templates-by-vegacorp/views/whats-new/1.1.15.php): failed to open stream: No such file or directory
- > GET request to /wp-admin/admin.php?page=wcpt_whats_new
- > Warning in wp-content/plugins/custom-page-templates-by-vegacorp/vendor/vegacorp/vg-freemius-sdk/index.php+164
include(): Failed opening 'wp-content/plugins/custom-page-templates-by-vegacorp/views/whats-new/1.1.15.php' for inclusion (include_path='.:/usr/share/php')
- > GET request to /wp-admin/admin.php?page=wcpt_whats_new
- > Notice in wp-content/plugins/custom-page-templates-by-vegacorp/vendor/vegacorp/vg-freemius-sdk/index.php+166
Undefined variable: items
SRP 50% from 2 tests
🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
- 13× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Notice
Undefined variable: post in wp-content/plugins/custom-page-templates-by-vegacorp/views/metabox.php on line 2
- > PHP Fatal error
Uncaught Error: Call to undefined function VG_Page_Layouts_Instance() in wp-content/plugins/custom-page-templates-by-vegacorp/views/upgrade-message.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function did_action() in wp-content/plugins/custom-page-templates-by-vegacorp/vendor/tgmpa/tgm-plugin-activation/class-tgm-plugin-activation.php:2109
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/custom-page-templates-by-vegacorp/views/metabox.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function wp_create_nonce() in wp-content/plugins/custom-page-templates-by-vegacorp/vendor/vegacorp/vg-freemius-sdk/views/page-template.php:5
- > PHP Fatal error
Uncaught Error: Call to undefined function sanitize_html_class() in wp-content/plugins/custom-page-templates-by-vegacorp/views/sidebar.php:1
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/custom-page-templates-by-vegacorp/views/whats-new/1.1.0.php:4
- > PHP Fatal error
Uncaught Error: Call to undefined function _e() in wp-content/plugins/custom-page-templates-by-vegacorp/views/welcome-page-content.php:1
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/custom-page-templates-by-vegacorp/vendor/vegacorp/vg-freemius-sdk/samples/email-optin-form.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function did_action() in wp-content/plugins/custom-page-templates-by-vegacorp/vendor/tgmpa/tgm-plugin-activation/class-tgm-plugin-activation.php:2109
- > PHP Notice
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: custom pages, wp page templates, custom templates, wordpress templates, woocommerce templates
custom-page-templates-by-vegacorp/page-layouts.php 92% from 13 tests
The main PHP script in "WP Page Templates" version 1.1.15 is automatically included on every request by WordPress
It is important to fix the following:
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("custom-page-templates-by-vegacorp.php" instead of "page-layouts.php")
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected42,253 lines of code in 180 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 137 | 8,664 | 19,180 | 35,975 |
PO File | 17 | 1,449 | 1,993 | 4,842 |
Markdown | 4 | 185 | 0 | 778 |
JavaScript | 4 | 84 | 77 | 430 |
JSON | 1 | 0 | 0 | 110 |
CSS | 15 | 7 | 0 | 91 |
XML | 2 | 3 | 0 | 27 |
PHP code 50% from 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
It is recommended to fix the following
- Cyclomatic complexity of classes has to be reduced to less than 1000 (currently 3,087)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.62 |
Average class complexity | 82.43 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 3,087.00 |
Average method complexity | 4.52 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 94.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 60 | |
▷ Abstract classes | 2 | 3.33% |
▷ Concrete classes | 58 | 96.67% |
▷ Final classes | 0 | 0.00% |
Methods | 1,415 | |
▷ Static methods | 207 | 14.63% |
▷ Public methods | 1,000 | 70.67% |
▷ Protected methods | 40 | 2.83% |
▷ Private methods | 375 | 26.50% |
Functions | 107 | |
▷ Named functions | 106 | 99.07% |
▷ Anonymous functions | 1 | 0.93% |
Constants | 153 | |
▷ Global constants | 103 | 67.32% |
▷ Class constants | 50 | 32.68% |
▷ Public constants | 50 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
4 PNG files occupy 0.05MB with 0.02MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
vendor/freemius/wordpress-sdk/assets/img/theme-icon.png | 10.97KB | 5.78KB | ▼ 47.37% |
assets/imgs/logo.png | 7.44KB | 3.88KB | ▼ 47.91% |
vendor/freemius/wordpress-sdk/assets/img/custom-page-templates-by-vegacorp.png | 21.61KB | 10.06KB | ▼ 53.42% |
vendor/freemius/wordpress-sdk/assets/img/plugin-icon.png | 9.16KB | 5.26KB | ▼ 42.58% |