Benchmarks
Plugin footprint 40% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
It is recommended to fix the following installer errors
- Install procedure had errors
- > Deprecated in wp-content/plugins/discordian-date-function/ddatefunc.php+146
Methods with the same name as their class will not be constructors in a future version of PHP; Discordian_Date_Widget has a deprecated constructor
Server metrics [RAM: ▼1.70MB] [CPU: ▼47.48ms] Passed 4 tests
Server-side resources used by Discordian Date Function
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.29 ▼1.17 | 9.81 ▼30.21 |
Dashboard /wp-admin | 2.30 ▼1.00 | 12.42 ▼36.11 |
Posts /wp-admin/edit.php | 2.30 ▼1.05 | 11.84 ▼39.48 |
Add New Post /wp-admin/post-new.php | 2.30 ▼3.58 | 12.01 ▼84.13 |
Media Library /wp-admin/upload.php | 2.30 ▼0.92 | 11.15 ▼26.45 |
Server storage [IO: ▲0.06MB] [DB: ▲0.00MB] Passed 3 tests
Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 12 new options
New WordPress options |
---|
dtime_convert |
can_compress_scripts |
dtime_widget |
widget_theysaidso_widget |
ddatefunc_change |
dtimefunc_change |
widget_recent-comments |
widget_discordian_date_func |
widget_recent-posts |
db_upgraded |
... |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Discordian Date Function
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,795 ▲34 | 14.43 ▼0.00 | 2.93 ▲1.24 | 45.54 ▲3.27 |
Dashboard /wp-admin | 2,196 ▲16 | 5.55 ▼0.04 | 85.78 ▼12.72 | 39.49 ▼2.28 |
Posts /wp-admin/edit.php | 2,101 ▲4 | 1.99 ▼0.05 | 37.76 ▼1.37 | 34.46 ▼6.47 |
Add New Post /wp-admin/post-new.php | 1,529 ▼3 | 17.81 ▼5.42 | 685.23 ▼18.20 | 61.13 ▼15.06 |
Media Library /wp-admin/upload.php | 1,404 ▲1 | 4.25 ▲0.13 | 108.81 ▲3.66 | 46.59 ▼1.61 |
Discordian Date Function Settings /wp-admin/ddatefunc.php | 26 | 0.44 | 0.09 | 17.75 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
- The plugin did not uninstall gracefully
- > User deprecated in wp-includes/functions.php+5546
The called constructor method for WP_Widget class in Discordian_Date_Widget is deprecated since version 4.3.0! Use __construct() instead.
- Zombie WordPress options detected upon uninstall: 7 options
- widget_theysaidso_widget
- can_compress_scripts
- widget_recent-comments
- db_upgraded
- widget_recent-posts
- theysaidso_admin_options
- widget_discordian_date_func
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test
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 take a closer look at the following
- 1× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/discordian-date-function/ddatefunc.php:146
- > PHP Fatal error
User-side errors 0% from 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
These are user-side errors you should fix
- > GET request to /wp-admin/ddatefunc.php
- > Network (severe)
wp-admin/ddatefunc.php - Failed to load resource: the server responded with a status of 404 (Not Found)
Optimizations
Plugin configuration 93% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
10 plugin tags: erisian, dtime, widget, eris, time...
discordian-date-function/ddatefunc.php 85% from 13 tests
The main file in "Discordian Date Function" v. 2.555 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
- Main file name: Name the main plugin file the same as the plugin slug ("discordian-date-function.php" instead of "ddatefunc.php")
- Description: Keep the plugin description shorter than 140 characters (currently 254 characters long)
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin625 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 41 | 13 | 460 |
JavaScript | 1 | 8 | 24 | 165 |
PHP code 50% from 2 tests
Analyzing cyclomatic complexity and code structure
These items need your attention
- Cyclomatic complexity of methods should be reduced to less than 100 (currently 114)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.64 |
Average class complexity | 114.00 |
▷ Minimum class complexity | 114.00 |
▷ Maximum class complexity | 114.00 |
Average method complexity | 29.25 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 114.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 4 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 4 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 15 | |
▷ Named functions | 15 | 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
All PNG images should be compressed to minimize bandwidth usage for end users
1 PNG file occupies 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-1.png | 28.32KB | 12.35KB | ▼ 56.38% |