Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully
Server metrics [RAM: ▲0.28MB] [CPU: ▼4.34ms] Passed 4 tests
Analyzing server-side resources used by Gist API Code insert
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.79 ▲0.32 | 36.87 ▼2.70 |
Dashboard /wp-admin | 3.62 ▲0.31 | 42.62 ▼4.44 |
Posts /wp-admin/edit.php | 3.67 ▲0.31 | 51.55 ▲2.87 |
Add New Post /wp-admin/post-new.php | 6.15 ▲0.26 | 82.78 ▼13.08 |
Media Library /wp-admin/upload.php | 3.48 ▲0.25 | 38.80 ▲5.33 |
Server storage [IO: ▲5.33MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 1,718 new files
Database: no new tables, 6 new options
New WordPress options |
---|
theysaidso_admin_options |
widget_recent-posts |
can_compress_scripts |
widget_theysaidso_widget |
widget_recent-comments |
db_upgraded |
Browser metrics Passed 4 tests
Checking browser requirements for Gist API Code insert
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,844 ▲98 | 14.40 ▲0.11 | 1.84 ▲0.21 | 37.24 ▼5.88 |
Dashboard /wp-admin | 2,222 ▲34 | 4.86 ▼0.22 | 110.14 ▲0.23 | 42.46 ▲6.24 |
Posts /wp-admin/edit.php | 2,105 ▲13 | 2.02 ▼0.10 | 33.42 ▼7.34 | 32.96 ▼1.32 |
Add New Post /wp-admin/post-new.php | 6,368 ▲4,854 | 28.05 ▲10.48 | 917.21 ▲218.37 | 56.80 ▲2.92 |
Media Library /wp-admin/upload.php | 1,407 ▲16 | 4.20 ▼0.01 | 92.17 ▼4.06 | 40.14 ▼4.82 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
- Zombie WordPress options were found after uninstall: 6 options
- widget_theysaidso_widget
- widget_recent-comments
- theysaidso_admin_options
- can_compress_scripts
- db_upgraded
- widget_recent-posts
Smoke tests 50% 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)
Even though everything seems fine, this is not an exhaustive test
SRP 0% 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
- 3× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/ap-gist-api-code-insert/src/templates/channel.blade.php
- > /wp-content/plugins/ap-gist-api-code-insert/src/templates/channel-load.blade.php
- > /wp-content/plugins/ap-gist-api-code-insert/src/templates/error.blade.php
- 273× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Interface 'Symfony\\Contracts\\Translation\\TranslatorInterface' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/symfony/translation/IdentityTranslator.php:23
- > PHP Fatal error
Uncaught Error: Class 'Carbon\\Translator' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/nesbot/carbon/src/Carbon/TranslatorImmutable.php:18
- > PHP Fatal error
Uncaught Error: Interface 'Carbon\\CarbonInterface' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/nesbot/carbon/src/Carbon/Carbon.php:510
- > PHP Fatal error
Uncaught Error: Interface 'Carbon\\Exceptions\\InvalidArgumentException' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/nesbot/carbon/src/Carbon/Exceptions/NotLocaleAwareException.php:17
- > PHP Fatal error
Uncaught Error: Class 'Illuminate\\Support\\Facades\\Facade' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/illuminate/support/Facades/Validator.php:15
- > PHP Fatal error
Uncaught Error: Class 'Illuminate\\Support\\Facades\\Facade' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/illuminate/support/Facades/Crypt.php:16
- > PHP Fatal error
Uncaught Error: Class 'Symfony\\Component\\Translation\\Exception\\RuntimeException' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/symfony/translation/Exception/ProviderException.php:19
- > PHP Fatal error
Uncaught Error: Class 'Illuminate\\Support\\Facades\\Facade' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/illuminate/support/Facades/RateLimiter.php:19
- > PHP Fatal error
Uncaught Error: Class 'Illuminate\\Bus\\PendingBatch' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/illuminate/support/Testing/Fakes/PendingBatchFake.php:8
- > PHP Fatal error
Uncaught Error: Class 'Symfony\\Component\\Translation\\Dumper\\FileDumper' not found in wp-content/plugins/ap-gist-api-code-insert/vendor/symfony/translation/Dumper/JsonFileDumper.php:21
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side
Optimizations
Plugin configuration 90% from 29 tests
readme.txt Passed 16 tests
The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
3 plugin tags: github, gist, code highlight
ap-gist-api-code-insert/social-patch.php 77% from 13 tests
The main PHP file in "Gist API Code insert" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
- 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
- Domain Path: The domain path points to an invalid folder, "/languages" does not exist
- Main file name: Please rename the main PHP file in this plugin to the plugin slug ("ap-gist-api-code-insert.php" instead of "social-patch.php")
Code Analysis 3% from 3 tests
File types 0% from 1 test
🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Almost there! Just fix the following issues
- You should never include executable (binary) or otherwise dangerous files in your plugin
- .bat - Batch File in Windows
- ☣ wp-content/plugins/ap-gist-api-code-insert/vendor/nesbot/carbon/bin/carbon.bat
- .bat - Batch File in Windows
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1,422 | 12,758 | 44,890 | 59,682 |
JSON | 30 | 0 | 0 | 20,339 |
XSD | 3 | 92 | 48 | 2,803 |
JavaScript | 9 | 91 | 84 | 1,241 |
Markdown | 19 | 409 | 1 | 1,025 |
SVG | 2 | 0 | 0 | 257 |
Sass | 2 | 33 | 0 | 218 |
Blade | 3 | 5 | 0 | 87 |
reStructuredText | 1 | 74 | 78 | 74 |
DOS Batch | 1 | 0 | 0 | 4 |
CSS | 3 | 0 | 0 | 3 |
YAML | 1 | 0 | 0 | 2 |
PHP code 50% from 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
It is recommended to fix the following
- Cyclomatic complexity of methods has to be reduced to less than 100 (currently 140)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.39 |
Average class complexity | 8.81 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 323.00 |
Average method complexity | 2.28 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 140.00 |
Code structure | ||
---|---|---|
Namespaces | 102 | |
Interfaces | 149 | |
Traits | 62 | |
Classes | 360 | |
▷ Abstract classes | 24 | 6.67% |
▷ Concrete classes | 336 | 93.33% |
▷ Final classes | 40 | 11.90% |
Methods | 4,251 | |
▷ Static methods | 704 | 16.56% |
▷ Public methods | 3,563 | 83.82% |
▷ Protected methods | 545 | 12.82% |
▷ Private methods | 143 | 3.36% |
Functions | 668 | |
▷ Named functions | 141 | 21.11% |
▷ Anonymous functions | 527 | 78.89% |
Constants | 208 | |
▷ Global constants | 12 | 5.77% |
▷ Class constants | 196 | 94.23% |
▷ Public constants | 191 | 97.45% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
screenshot-2.png | 16.67KB | 8.79KB | ▼ 47.30% |
screenshot-1.png | 15.16KB | 6.33KB | ▼ 58.22% |