Benchmarks
Plugin footprint 82% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully
Server metrics [RAM: ▲0.61MB] [CPU: ▼0.01ms] 75% from 4 tests
Analyzing server-side resources used by Custom Fonts - Host Your Fonts Locally
Please take the time to fix the following items
- RAM: Try to keep total memory usage under 10MB (currently 10.26MB on /wp-admin/themes.php?page=bsf-custom-fonts)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.89 ▲0.42 | 49.72 ▲7.12 |
Dashboard /wp-admin | 4.00 ▲0.65 | 54.52 ▼9.04 |
Posts /wp-admin/edit.php | 4.05 ▲0.69 | 57.57 ▲8.33 |
Add New Post /wp-admin/post-new.php | 6.64 ▲0.74 | 92.68 ▼2.16 |
Media Library /wp-admin/upload.php | 3.90 ▲0.67 | 41.88 ▲4.04 |
Custom Fonts /wp-admin/themes.php?page=bsf-custom-fonts | 10.26 | 74.77 |
Server storage [IO: ▲2.50MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 71 new files
Database: no new tables, 8 new options
New WordPress options |
---|
db_upgraded |
widget_recent-comments |
theysaidso_admin_options |
_custom_fonts_db_version |
can_compress_scripts |
widget_recent-posts |
bcf_custom_fonts_2_0_2_migration |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Custom Fonts - Host Your Fonts Locally
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,935 ▲188 | 14.44 ▲0.17 | 1.56 ▼0.18 | 38.96 ▼5.74 |
Dashboard /wp-admin | 2,340 ▲165 | 6.16 ▲0.47 | 120.53 ▲16.12 | 41.68 ▼3.00 |
Posts /wp-admin/edit.php | 2,274 ▲174 | 3.41 ▲1.39 | 55.12 ▲14.74 | 35.05 ▼0.90 |
Add New Post /wp-admin/post-new.php | 1,535 ▲9 | 23.27 ▲0.22 | 574.65 ▼45.56 | 32.92 ▼15.02 |
Media Library /wp-admin/upload.php | 1,402 ▲2 | 4.21 ▲0.13 | 83.72 ▼24.52 | 42.23 ▼2.60 |
Custom Fonts /wp-admin/themes.php?page=bsf-custom-fonts | 1,140 | 8.99 | 194.13 | 49.31 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
- The uninstall procedure has failed, leaving 8 options in the database
- theysaidso_admin_options
- widget_recent-comments
- widget_theysaidso_widget
- can_compress_scripts
- _custom_fonts_db_version
- widget_recent-posts
- bcf_custom_fonts_2_0_2_migration
- db_upgraded
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested
SRP 50% from 2 tests
🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
- 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Fatal error
require_once(): Failed opening required 'BSF_CUSTOM_FONTS_DIRincludes/plugin-update/class-custom-fonts-update.php' (include_path='.:/usr/share/php') in wp-content/plugins/custom-fonts/classes/class-bsf-custom-fonts.php on line 56
- > PHP Warning
Use of undefined constant BSF_CUSTOM_FONTS_DIR - assumed 'BSF_CUSTOM_FONTS_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/custom-fonts/classes/class-bsf-custom-fonts.php on line 56
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/custom-fonts/classes/class-bsf-custom-fonts-white-label.php:56
- > PHP Warning
require_once(BSF_CUSTOM_FONTS_DIRincludes/plugin-update/class-custom-fonts-update.php): failed to open stream: No such file or directory in wp-content/plugins/custom-fonts/classes/class-bsf-custom-fonts.php on line 56
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
9 plugin tags: performance, full site editing, custom fonts, typography, privacy...
custom-fonts/custom-fonts.php 92% from 13 tests
"Custom Fonts - Host Your Fonts Locally" version 2.1.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
- Description: Please don't use more than 140 characters for the plugin description (currently 295 characters long)
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin52,384 lines of code in 69 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JSON | 3 | 1 | 0 | 26,826 |
PHP | 23 | 760 | 1,951 | 19,604 |
JavaScript | 34 | 321 | 99 | 3,426 |
CSS | 8 | 267 | 226 | 2,201 |
Sass | 1 | 19 | 0 | 327 |
PHP code Passed 2 tests
An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.44 |
Average class complexity | 21.89 |
▷ Minimum class complexity | 2.00 |
▷ Maximum class complexity | 89.00 |
Average method complexity | 3.12 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 17.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 18 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 18 | 100.00% |
▷ Final classes | 2 | 11.11% |
Methods | 171 | |
▷ Static methods | 40 | 23.39% |
▷ Public methods | 140 | 81.87% |
▷ Protected methods | 10 | 5.85% |
▷ Private methods | 21 | 12.28% |
Functions | 17 | |
▷ Named functions | 12 | 70.59% |
▷ Anonymous functions | 5 | 29.41% |
Constants | 13 | |
▷ Global constants | 13 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.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
There are no PNG files in this plugin