Benchmarks
Plugin footprint 64% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully
Server metrics [RAM: ▲0.77MB] [CPU: ▲8.10ms] 75% from 4 tests
An overview of server-side resources used by CodeBard's Patron Button and Widgets for Patreon
The following require your attention
- CPU: Total CPU usage should be kept under 500.00ms (currently 3,814.21ms on /wp-admin/admin.php?page=cb_p6_install_pw)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.24 ▲0.77 | 41.22 ▼1.08 |
Dashboard /wp-admin | 4.12 ▲0.77 | 63.88 ▲8.17 |
Posts /wp-admin/edit.php | 4.15 ▲0.79 | 68.06 ▲18.26 |
Add New Post /wp-admin/post-new.php | 6.66 ▲0.78 | 92.31 ▲8.94 |
Media Library /wp-admin/upload.php | 3.99 ▲0.76 | 49.75 ▲16.36 |
Installing Patreon WordPress /wp-admin/admin.php?page=cb_p6_install_pw | 5.39 | 3,814.21 |
Admin message /wp-admin/admin.php?page=cb_p6admin_message | 5.10 | 96.94 |
Server storage [IO: ▲0.64MB] [DB: ▲0.03MB] 67% from 3 tests
Input-output and database impact of this plugin
Please fix the following
- There were 59 files (1,326.77KB) illegally modified outside of "wp-content/plugins/patron-button-and-widgets-by-codebard/" and "wp-content/uploads/"
- (new file) wp-content/plugins/patreon-connect/assets/fonts/Apache License.txt
- (new file) wp-content/plugins/patreon-connect/assets/fonts/librefranklin-extrabold-webfont.ttf
- (new file) wp-content/plugins/patreon-connect/assets/fonts/OpenSans-Bold.ttf
- (new file) wp-content/plugins/patreon-connect/assets/fonts/LibreFranklin-ExtraBold.ttf
- (new file) wp-content/plugins/patreon-connect/assets/css/app.css
- (new file) wp-content/plugins/patreon-connect/assets/css/admin.css
- (new file) wp-content/plugins/patreon-connect/assets/fonts/librefranklin-extrabold-webfont.woff
- (new file) wp-content/plugins/patreon-connect/assets/fonts/OFL.txt
- (new file) wp-content/plugins/patreon-connect/NOTICE
- (new file) wp-content/plugins/patreon-connect/LICENSE
- ...
Filesystem: 64 new files
Database: no new tables, 20 new options
New WordPress options |
---|
cb_p6_first_activated |
patreon-installation-api-version |
widget_patreon_sidebar_user_widget |
patreon-setup_is_being_done |
can_compress_scripts |
db_upgraded |
widget_patreon_sidebar_goals_site_widget |
patreon-creator-tiers |
widget_recent-posts |
cb_p6_options |
... |
Browser metrics Passed 4 tests
CodeBard's Patron Button and Widgets for Patreon: an overview of browser usage
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,102 ▲340 | 15.47 ▲1.12 | 1.58 ▼0.22 | 28.78 ▼15.25 |
Dashboard /wp-admin | 2,514 ▲340 | 7.25 ▲1.69 | 142.28 ▲47.20 | 107.07 ▲62.82 |
Posts /wp-admin/edit.php | 2,394 ▲294 | 3.93 ▲1.98 | 93.56 ▲55.64 | 81.24 ▲36.60 |
Add New Post /wp-admin/post-new.php | 1,605 ▲79 | 19.86 ▼3.86 | 605.99 ▼9.15 | 39.04 ▼17.95 |
Media Library /wp-admin/upload.php | 1,522 ▲122 | 5.06 ▲0.88 | 98.55 ▼10.35 | 96.67 ▲53.70 |
Installing Patreon WordPress /wp-admin/admin.php?page=cb_p6_install_pw | 1,120 | 3.77 | 64.08 | 41.80 |
Admin message /wp-admin/admin.php?page=cb_p6admin_message | 1,034 | 3.16 | 41.34 | 62.16 |
Uninstaller [IO: ▲1.30MB] [DB: ▲0.03MB] 50% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
- This plugin cannot be uninstalled
- > Notice in wp-content/plugins/patron-button-and-widgets-by-codebard/uninstall.php+53
Undefined index: prefix
- The uninstall procedure has failed, leaving 21 options in the database
- patreon-rewrite-rules-flushed
- cb_p6_options
- widget_patreon_sidebar_site_widget
- patreon-installation-api-version
- patreon-creator-has-tiers
- patreon-setup_is_being_done
- can_compress_scripts
- theysaidso_admin_options
- db_upgraded
- widget_recent-posts
- ...
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested
SRP 0% 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
- 5× GET requests to PHP files return non-empty strings:
- > /wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setting_sections/reset_settings_form.php
- > /wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setting_sections/admin_settings_form_footer.php
- > /wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setting_sections/admin_settings_page_footer.php
- > /wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setting_sections/admin_settings_page_header.php
- > /wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setting_sections/admin_settings_form_header.php
- 20× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'cb_p6_core' not found in wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/plugin.php:4
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setup_2.php:16
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setting_sections/extras.php:4
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setting_sections/dashboard.php:7
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setting_sections/post_button.php:3
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/pro_pitch_modal.php:6
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/patron-button-and-widgets-by-codebard/index.php:40
- > PHP Notice
Undefined index: site_account in wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/setup_2.php on line 16
- > PHP Fatal error
Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/widgets.php:104
- > PHP Fatal error
Uncaught Error: Using $this when not in object context in wp-content/plugins/patron-button-and-widgets-by-codebard/plugin/includes/default_internal_vars.php:6
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected
Optimizations
Plugin configuration 86% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed:
- Tags: Too many tags (31 tag instead of maximum 10); only the first 5 tags are used in your directory listing
patron-button-and-widgets-by-codebard/index.php 77% from 13 tests
This is the main PHP file of "CodeBard's Patron Button and Widgets for Patreon" version 2.2.0, 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:
- Domain Path: The domain path is invalid: folder "/lang" does not exist
- Text Domain: Please use dashes and lowercase characters for text domains
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("patron-button-and-widgets-by-codebard.php" instead of "index.php")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin5,488 lines of code in 44 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 29 | 2,245 | 405 | 4,763 |
CSS | 2 | 281 | 0 | 585 |
JavaScript | 4 | 31 | 5 | 113 |
Smarty | 9 | 0 | 0 | 27 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.41 |
Average class complexity | 77.62 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 418.00 |
Average method complexity | 4.56 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 94.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 8 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 8 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 172 | |
▷ Static methods | 2 | 1.16% |
▷ Public methods | 170 | 98.84% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 2 | 1.16% |
Functions | 2 | |
▷ Named functions | 2 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.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
12 PNG files occupy 0.17MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/woo_logo.png | 24.50KB | 9.82KB | ▼ 59.91% |
images/become_a_patron_button.png | 3.01KB | 1.62KB | ▼ 46.14% |
images/admin_delete_icon.png | 0.49KB | 0.43KB | ▼ 10.82% |
images/codebard_very_small.png | 3.42KB | 2.17KB | ▼ 36.50% |
images/logo.png | 10.84KB | 5.57KB | ▼ 48.62% |