Benchmarks
Plugin footprint 82% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.15MB] [CPU: ▼152.59ms] 75% from 4 tests
A check of server-side resources used by CM Business Directory
Please have a look at the following items
- CPU: You should keep total CPU usage under 500.00ms (currently 1,391.28ms on /wp-admin/edit.php?post_type=cm-business&page=cm-business-directory-settings)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.94 ▲0.10 | 32.54 ▲8.95 |
Dashboard /wp-admin | 3.26 ▲0.19 | 31.30 ▼5.04 |
Posts /wp-admin/edit.php | 3.30 ▲0.19 | 31.32 ▲0.65 |
Add New Post /wp-admin/post-new.php | 5.71 ▲0.27 | 70.09 ▼605.24 |
Media Library /wp-admin/upload.php | 3.13 ▲0.12 | 22.79 ▼0.72 |
User Guide /wp-admin/edit.php?post_type=cm-business&page=cmbd_about | 3.27 | 27.70 |
Settings /wp-admin/edit.php?post_type=cm-business&page=cm-business-directory-settings | 3.41 | 1,391.28 |
Add Business /wp-admin/post-new.php?post_type=cm-business | 5.71 | 72.04 |
Business /wp-admin/edit.php?post_type=cm-business | 3.18 | 23.05 |
Upgrade ➤ /wp-admin/edit.php?post_type=cm-business&page=cmbd_pro | 3.13 | 20.24 |
Categories /wp-admin/edit-tags.php?taxonomy=cm-business-category&post_type=cm-business | 3.13 | 28.42 |
Server storage [IO: ▲1.50MB] [DB: ▲0.01MB] Passed 3 tests
A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 130 new files
Database: no new tables, 2 new options
New WordPress options |
---|
cmbd_shortcode_page_id |
cmbd_permalink_old |
Browser metrics Passed 4 tests
This is an overview of browser requirements for CM Business Directory
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,731 ▲120 | 15.86 ▼0.10 | 4.74 ▼0.09 | 76.07 ▼3.72 |
Dashboard /wp-admin | 2,990 ▲91 | 6.12 ▼0.00 | 112.46 ▼24.95 | 178.19 ▼1.15 |
Posts /wp-admin/edit.php | 2,800 ▲60 | 3.23 ▲0.01 | 62.96 ▼1.21 | 143.76 ▼1.58 |
Add New Post /wp-admin/post-new.php | 3,845 ▲30 | 18.42 ▼0.66 | 426.25 ▲6.86 | 155.59 ▼7.70 |
Media Library /wp-admin/upload.php | 1,810 ▲58 | 5.54 ▲0.13 | 133.68 ▼13.79 | 190.60 ▲15.19 |
User Guide /wp-admin/edit.php?post_type=cm-business&page=cmbd_about | 5,619 | 13.64 | 352.68 | 297.04 |
Settings /wp-admin/edit.php?post_type=cm-business&page=cm-business-directory-settings | 5,077 | 7.15 | 154.40 | 256.87 |
Add Business /wp-admin/post-new.php?post_type=cm-business | 7,714 | 21.59 | 463.31 | 210.88 |
Business /wp-admin/edit.php?post_type=cm-business | 1,546 | 3.08 | 57.44 | 119.95 |
Upgrade ➤ /wp-admin/edit.php?post_type=cm-business&page=cmbd_pro | 1,908 | 3.09 | 64.53 | 121.47 |
Categories /wp-admin/edit-tags.php?taxonomy=cm-business-category&post_type=cm-business | 1,812 | 2.78 | 59.97 | 132.27 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.01MB] 75% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
- This plugin does not fully uninstall, leaving 2 options in the database
- cmbd_shortcode_page_id
- cmbd_permalink_old
Smoke tests 25% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Almost there, just fix the following server-side errors
- > GET request to /wp-admin/edit.php?post_type=cm-business&page=cmbd_about
- > Warning in wp-content/plugins/cm-business-directory/package/cminds-free.php+3001
mysqli_get_server_info() expects exactly 1 parameter, 0 given
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
Please fix the following items
- 15× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
- > PHP Warning
include_once(): Failed opening 'CMBD_PLUGIN_DIRbackend/classes/SettingsViewAbstract.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/cm-business-directory/backend/classes/SettingsView.php on line 2
- > PHP Warning
include_once(): Failed opening 'CMBD_PLUGIN_DIR/frontend/classes/Template.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/cm-business-directory/frontend/templates/cm_default/business-page-view.php on line 3
- > PHP Warning
include_once(CMBD_PLUGIN_DIRbackend/classes/SettingsViewAbstract.php): failed to open stream: No such file or directory in wp-content/plugins/cm-business-directory/backend/classes/SettingsView.php on line 2
- > PHP Warning
Use of undefined constant CMBD_PLUGIN_DIR - assumed 'CMBD_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/cm-business-directory/backend/cm-business-directory-backend.php on line 3
- > PHP Fatal error
Uncaught Error: Class 'CMBD_SettingsViewAbstract' not found in wp-content/plugins/cm-business-directory/backend/classes/SettingsView.php:4
- > PHP Fatal error
Uncaught Error: Class 'CMBDBusinessPageTemplate' not found in wp-content/plugins/cm-business-directory/frontend/templates/cm_default/business-page-view.php:5
- > PHP Warning
Use of undefined constant CMBD_PLUGIN_DIR - assumed 'CMBD_PLUGIN_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/cm-business-directory/frontend/templates/cm_default/business-page-view.php on line 3
- > PHP Warning
include_once(CMBD_PLUGIN_DIR/frontend/classes/Template.php): failed to open stream: No such file or directory in wp-content/plugins/cm-business-directory/frontend/templates/cm_default/business-page-view.php on line 3
- > PHP Warning
include_once(CMBD_PLUGIN_DIR/frontend/cm-business-directory-business-page.php): failed to open stream: No such file or directory in wp-content/plugins/cm-business-directory/backend/cm-business-directory-backend.php on line 3
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/cm-business-directory/package/views/registration.php:42
- > PHP Warning
User-side errors 0% from 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
These are user-side errors you should fix
- > GET request to /wp-admin/edit.php?post_type=cm-business&page=cmbd_about
- > Console-api (severe) in unknown
https://static.xx.fbcdn.net/rsrc.php/v3/yc/r/gGTO4iuWbYx.js?_nc_x=Ij3Wp8lg5Kz 57:562 "ErrorUtils caught an error:\n\nCannot listen to an undefined element. [Caught in: Tried to listen to element of type click]\n\nSubsequent non-fatal errors won't be logged; see https://fburl.com/debugjs."
- > GET request to /wp-admin/edit.php?post_type=cm-business&page=cm-business-directory-settings
- > Other (warning) in unknown
/wp-admin/edit.php?post_type=cm-business&page=cm-business-directory-settings 982 Allow attribute will take precedence over 'allowfullscreen'.
- > GET request to /wp-admin/post-new.php?post_type=cm-business
- > Console-api (warning) in wp-includes/js/dist/blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156+1:40463
Block validation: Expected attribute `%s` of value `%s`, saw `%s`." "style" "height:100px" "height:5px
- > GET request to /wp-admin/post-new.php?post_type=cm-business
- > Console-api (severe) in wp-includes/js/dist/blocks.min.js?ver=7ed7fe32dad771c4e0af4f56539ff156+1:40463
Block validation: Block validation failed for `%s` (%o).\n\nContent generated by `save` function:\n\n%s\n\nContent retrieved from post body:\n\n%s" "core/spacer" Object "\u003Cdiv style=\"height:100px\" aria-hidden=\"true\" class=\"wp-block-spacer\">\u003C/div>" "\u003Cdiv style=\"height:5px\" aria-hidden=\"true\" class=\"wp-block-spacer\">\u003C/div>
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: catalog, directory plugin, classified, business directory, directory
cm-business-directory/cm-business-directory.php Passed 13 tests
This is the main PHP file of "CM Business Directory" version 1.3.2, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
58 characters long description:
Build, organize and display a local directory of business.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected9,593 lines of code in 53 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 38 | 1,172 | 743 | 7,423 |
CSS | 8 | 223 | 68 | 1,799 |
JavaScript | 6 | 41 | 22 | 232 |
Sass | 1 | 23 | 2 | 139 |
PHP code Passed 2 tests
Cyclomatic complexity and code structure are the fingerprint of this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.35 |
Average class complexity | 42.21 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 251.00 |
Average method complexity | 3.49 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 38.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 14 | |
▷ Abstract classes | 2 | 14.29% |
▷ Concrete classes | 12 | 85.71% |
▷ Final classes | 0 | 0.00% |
Methods | 235 | |
▷ Static methods | 118 | 50.21% |
▷ Public methods | 196 | 83.40% |
▷ Protected methods | 34 | 14.47% |
▷ Private methods | 5 | 2.13% |
Functions | 10 | |
▷ Named functions | 9 | 90.00% |
▷ Anonymous functions | 1 | 10.00% |
Constants | 73 | |
▷ Global constants | 11 | 15.07% |
▷ Class constants | 62 | 84.93% |
▷ Public constants | 62 | 100.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
63 PNG files occupy 0.86MB with 0.42MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
package/css/images/ui-icons_2e83ff_256x240.png | 4.44KB | 4.17KB | ▼ 6.02% |
package/views/banner_yearly-membership_220px.png | 31.34KB | 10.91KB | ▼ 65.19% |
package/views/img/assets.png | 16.34KB | 6.92KB | ▼ 57.67% |
package/views/routes.png | 12.59KB | 4.78KB | ▼ 62.02% |
backend/assets/css/images/ui-bg_glass_95_fef1ec_1x400.png | 0.32KB | 0.15KB | ▼ 54.82% |