Benchmarks
Plugin footprint 83% 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.07MB] [CPU: ▼9.06ms] Passed 4 tests
This is a short check of server-side resources used by DK PDF
Normal server usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.51 ▲0.04 | 34.92 ▼9.69 |
Dashboard /wp-admin | 3.38 ▲0.07 | 44.77 ▼2.12 |
Posts /wp-admin/edit.php | 3.49 ▲0.14 | 44.80 ▼3.13 |
Add New Post /wp-admin/post-new.php | 5.96 ▲0.07 | 80.22 ▼21.28 |
Media Library /wp-admin/upload.php | 3.30 ▲0.07 | 36.42 ▲0.20 |
DK PDF /wp-admin/admin.php?page=dkpdf_settings | 3.30 | 36.38 |
Addons /wp-admin/admin.php?page=dkpdf-addons | 3.26 | 27.15 |
Server storage [IO: ▲21.24MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 784 new files
Database: no new tables, 6 new options
New WordPress options |
---|
theysaidso_admin_options |
can_compress_scripts |
widget_recent-posts |
db_upgraded |
widget_recent-comments |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for DK PDF
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,939 ▲168 | 13.56 ▼0.81 | 5.87 ▲3.86 | 37.88 ▼7.58 |
Dashboard /wp-admin | 2,236 ▲48 | 4.88 ▼0.03 | 101.05 ▼7.84 | 38.76 ▼9.45 |
Posts /wp-admin/edit.php | 2,113 ▲24 | 2.04 ▲0.01 | 35.29 ▼5.53 | 31.89 ▼4.37 |
Add New Post /wp-admin/post-new.php | 1,536 ▲8 | 17.49 ▼5.81 | 671.52 ▲72.58 | 60.51 ▲8.44 |
Media Library /wp-admin/upload.php | 1,412 ▲21 | 4.30 ▲0.10 | 105.92 ▲6.88 | 48.02 ▲2.80 |
DK PDF /wp-admin/admin.php?page=dkpdf_settings | 1,114 | 3.86 | 60.59 | 26.22 |
Addons /wp-admin/admin.php?page=dkpdf-addons | 788 | 2.05 | 24.44 | 27.56 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
- This plugin does not fully uninstall, leaving 6 options in the database
- widget_recent-posts
- db_upgraded
- can_compress_scripts
- widget_theysaidso_widget
- theysaidso_admin_options
- widget_recent-comments
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
- 146× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\Tag\\InlineTag' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Tag/Cite.php:5
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\Tag\\InlineTag' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Tag/Em.php:5
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\Tag\\BlockTag' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Tag/FieldSet.php:5
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\Barcode\\AbstractBarcode' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Barcode/Code39.php:8
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\Tag\\Tag' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Tag/TextCircle.php:8
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\MpdfException' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Exception/InvalidArgumentException.php:5
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\Tag\\BlockTag' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Tag/Div.php:5
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\Tag\\BlockTag' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Tag/H4.php:5
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\Tag\\BlockTag' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Tag/Nav.php:5
- > PHP Fatal error
Uncaught Error: Class 'Mpdf\\Tag\\BlockTag' not found in wp-content/plugins/dk-pdf/vendor/mpdf/mpdf/src/Tag/Section.php:5
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side
Optimizations
Plugin configuration 87% from 29 tests
readme.txt 88% from 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
- Screenshots: These screenshots do not have images: #1 (Front-end PDF Button), #2 (PDF Button settings), #3 (PDF Setup settings), #4 (PDF Header & Footer settings), #5 (PDF Custom CSS), #6 (Disable PDF Button Metabox)
- Tags: Too many tags (12 tag instead of maximum 10); only the first 5 tags are used in your directory listing
dk-pdf/dk-pdf.php 85% from 13 tests
"DK PDF" version 1.9.6's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
You should first fix the following items:
- Requires at least: Required version must be the same as the one declared in readme.txt ("3.9.6" instead of "3.9")
- Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
Code Analysis 95% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin75,797 lines of code in 343 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 315 | 9,388 | 10,454 | 73,934 |
Markdown | 6 | 216 | 0 | 768 |
CSS | 4 | 79 | 18 | 454 |
JSON | 5 | 29 | 0 | 379 |
JavaScript | 7 | 32 | 14 | 96 |
PO File | 1 | 25 | 27 | 66 |
XML | 3 | 9 | 0 | 66 |
YAML | 1 | 11 | 0 | 31 |
Bourne Shell | 1 | 2 | 0 | 3 |
PHP code 0% from 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
Please fix the following
- Cyclomatic complexity of classes has to be reduced to less than 1000 (currently 7,591)
- Please reduce cyclomatic complexity of methods to less than 100 (currently 460)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.52 |
Average class complexity | 79.82 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 7,591.00 |
Average method complexity | 16.47 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 460.00 |
Code structure | ||
---|---|---|
Namespaces | 22 | |
Interfaces | 5 | |
Traits | 2 | |
Classes | 215 | |
▷ Abstract classes | 7 | 3.26% |
▷ Concrete classes | 208 | 96.74% |
▷ Final classes | 1 | 0.48% |
Methods | 1,153 | |
▷ Static methods | 82 | 7.11% |
▷ Public methods | 1,000 | 86.73% |
▷ Protected methods | 33 | 2.86% |
▷ Private methods | 120 | 10.41% |
Functions | 67 | |
▷ Named functions | 61 | 91.04% |
▷ Anonymous functions | 6 | 8.96% |
Constants | 392 | |
▷ Global constants | 12 | 3.06% |
▷ Class constants | 380 | 96.94% |
▷ Public constants | 380 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG images were found in this plugin