Benchmarks
Plugin footprint 57% 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
- The plugin cannot be installed
- > Notice in wp-content/plugins/2step-reviews-app/two-step-reviews-app.php+94
date_default_timezone_set(): Timezone ID '' is invalid
Server metrics [RAM: ▼1.94MB] [CPU: ▼355.57ms] Passed 4 tests
A check of server-side resources used by 2 Step Reviews
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.43 ▼1.09 | 7.48 ▼49.78 |
Dashboard /wp-admin | 2.45 ▼0.96 | 7.23 ▼26.57 |
Posts /wp-admin/edit.php | 2.45 ▼1.20 | 7.29 ▼34.58 |
Add New Post /wp-admin/post-new.php | 2.45 ▼4.53 | 6.93 ▼1,294.10 |
Media Library /wp-admin/upload.php | 2.45 ▼0.85 | 6.78 ▼43.83 |
Reviews /wp-admin/admin.php?page=2step-reviews-app/show-reviews.php | 2.45 | 9.09 |
2Step /wp-admin/admin.php?page=2step-reviews-app/config-page.php | 2.45 | 7.82 |
Server storage [IO: ▲3.04MB] [DB: ▲0.00MB] 67% from 3 tests
A short overview of filesystem and database impact
Please fix the following
- There were 1 file (0.00KB) illegally modified outside of "wp-content/plugins/2step-reviews-app/" and "wp-content/uploads/"
- (new file) "wp-content/plugins/2step-reviews-app/assets/images/logo-256\303\227256.png"
Filesystem: 887 new files
Database: no new tables, no new options
Browser metrics Passed 4 tests
This is an overview of browser requirements for 2 Step Reviews
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,834 ▲112 | 15.86 ▲0.18 | 6.26 ▲0.82 | 2.50 ▲0.25 |
Dashboard /wp-admin | 2,920 ▲59 | 6.14 ▼0.06 | 118.74 ▼13.10 | 182.05 ▲2.36 |
Posts /wp-admin/edit.php | 2,722 ▲37 | 3.13 ▼0.12 | 68.21 ▼1.60 | 154.33 ▲7.83 |
Add New Post /wp-admin/post-new.php | 1,697 ▼55 | 15.62 ▼5.38 | 410.74 ▼80.18 | 191.15 ▼19.37 |
Media Library /wp-admin/upload.php | 1,732 ▲34 | 5.50 ▲0.03 | 122.78 ▼31.21 | 215.09 ▲19.41 |
Reviews /wp-admin/admin.php?page=2step-reviews-app/show-reviews.php | 984 | 2.37 | 51.64 | 91.06 |
2Step /wp-admin/admin.php?page=2step-reviews-app/config-page.php | 1,393 | 2.38 | 54.80 | 218.38 |
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
- Uninstall procedure had uncaught errors
- > Notice in wp-content/plugins/2step-reviews-app/two-step-reviews-app.php+94
date_default_timezone_set(): Timezone ID '' is invalid
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=2step-reviews-app/config-page.php
- > Notice in wp-content/plugins/2step-reviews-app/two-step-reviews-app.php+94
date_default_timezone_set(): Timezone ID '' is invalid
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=2step-reviews-app/config-page.php
- > Deprecated in wp-includes/class-wp-hook.php+307
Non-static method Two_Step_Reviews_App::add_menu_admin() should not be called statically
- > GET request to /wp-admin/admin.php?page=2step-reviews-app/config-page.php
- > Notice in wp-content/plugins/2step-reviews-app/config-page.php+10
Undefined index: username
- > GET request to /wp-admin/admin.php?page=2step-reviews-app/config-page.php
- > Notice in wp-content/plugins/2step-reviews-app/config-page.php+32
Undefined index: action
- > GET request to /wp-admin/admin.php?page=2step-reviews-app/config-page.php
- > User deprecated in wp-content/plugins/2step-reviews-app/vendor/twig/twig/lib/Twig/Loader/Filesystem.php+7
Using the "Twig_Loader_Filesystem" class is deprecated since Twig version 2.7, use "Twig\Loader\FilesystemLoader" instead.
- > GET request to /wp-admin/admin.php?page=2step-reviews-app/config-page.php
- > User deprecated in wp-content/plugins/2step-reviews-app/vendor/twig/twig/lib/Twig/Environment.php+7
Using the "Twig_Environment" class is deprecated since Twig version 2.7, use "Twig\Environment" instead.
- > GET request to /wp-admin/admin.php?page=2step-reviews-app/config-page.php
- > User deprecated in wp-content/plugins/2step-reviews-app/vendor/twig/twig/lib/Twig/Extension/Debug.php+7
Using the "Twig_Extension_Debug" class is deprecated since Twig version 2.7, use "Twig\Extension\DebugExtension" instead.
- > GET request to /wp-admin/admin.php?page=2step-reviews-app/config-page.php
- > Deprecated in wp-content/plugins/2step-reviews-app/vendor/twig/twig/src/Node/Node.php+43
Unparenthesized `a ? b : c ? d : e` is deprecated. Use either `(a ? b : c) ? d : e` or `a ? b : (c ? d : e)`
- > GET request to /wp-admin/admin.php?page=2step-reviews-app/config-page.php
- > User deprecated in wp-content/plugins/2step-reviews-app/vendor/twig/twig/lib/Twig/SimpleFilter.php+19
Using the "Twig_SimpleFilter" class is deprecated since Twig version 2.7, use "Twig\TwigFilter" instead.
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
The following issues need your attention
- 326× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Interface 'GuzzleHttp\\Promise\\PromisorInterface' not found in wp-content/plugins/2step-reviews-app/vendor/guzzlehttp/promises/src/EachPromise.php:8
- > PHP Fatal error
Uncaught Error: Class 'Twig\\TokenParser\\AbstractTokenParser' not found in wp-content/plugins/2step-reviews-app/vendor/twig/twig/src/TokenParser/FromTokenParser.php:23
- > PHP Fatal error
Uncaught Error: Class 'Twig\\TokenParser\\AbstractTokenParser' not found in wp-content/plugins/2step-reviews-app/vendor/twig/twig/src/TokenParser/IfTokenParser.php:31
- > PHP Fatal error
Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/2step-reviews-app/vendor/composer/installers/src/Composer/Installers/AimeosInstaller.php:4
- > PHP Fatal error
Uncaught Error: Class 'Twig\\TokenParser\\AbstractTokenParser' not found in wp-content/plugins/2step-reviews-app/vendor/twig/twig/src/TokenParser/WithTokenParser.php:22
- > PHP Fatal error
Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/2step-reviews-app/vendor/composer/installers/src/Composer/Installers/CockpitInstaller.php:4
- > PHP Fatal error
Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/2step-reviews-app/vendor/composer/installers/src/Composer/Installers/KanboardInstaller.php:13
- > PHP Fatal error
Uncaught Error: Class 'Twig\ode\\Expression\\TestExpression' not found in wp-content/plugins/2step-reviews-app/vendor/twig/twig/src/Node/Expression/Test/DefinedTest.php:35
- > PHP Fatal error
Uncaught Error: Class 'Timber\\User' not found in wp-content/plugins/2step-reviews-app/vendor/timber/timber/lib/Integrations/CoAuthorsPlusUser.php:5
- > PHP Fatal error
Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/2step-reviews-app/vendor/composer/installers/src/Composer/Installers/AglInstaller.php:4
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 94% from 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
These attributes need to be fixed:
- Donate link: Please fix this invalid URI: ""
2step-reviews-app/two-step-reviews-app.php 85% from 13 tests
Analyzing the main PHP file in "2 Step Reviews" version 1.0.1
It is important to fix the following:
- Main file name: It is recommended to name the main PHP file as the plugin slug ("2step-reviews-app.php" instead of "two-step-reviews-app.php")
- Description: The description should be shorter than 140 characters (currently 197 characters long)
Code Analysis 5% from 3 tests
File types 0% from 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Please make sure to remedy the following
- For security reasons, never distribute binary or executable files with your plugin
- .bat - Batch File in Windows
- ☣ wp-content/plugins/2step-reviews-app/vendor/bin/var-dump-server.bat
- .bat - Batch File in Windows
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 649 | 7,340 | 15,146 | 32,938 |
Markdown | 55 | 2,307 | 0 | 6,334 |
reStructuredText | 92 | 2,094 | 1,934 | 2,729 |
JSON | 18 | 0 | 0 | 1,602 |
XML | 17 | 30 | 53 | 529 |
Bourne Shell | 5 | 58 | 15 | 265 |
Twig | 9 | 30 | 16 | 213 |
YAML | 8 | 34 | 2 | 189 |
make | 1 | 4 | 0 | 9 |
DOS Batch | 1 | 0 | 0 | 4 |
CSS | 2 | 0 | 47 | 2 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity problems
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.41 |
Average class complexity | 6.84 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 172.00 |
Average method complexity | 2.61 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 33.00 |
Code structure | ||
---|---|---|
Namespaces | 52 | |
Interfaces | 34 | |
Traits | 2 | |
Classes | 586 | |
▷ Abstract classes | 15 | 2.56% |
▷ Concrete classes | 571 | 97.44% |
▷ Final classes | 60 | 10.51% |
Methods | 2,307 | |
▷ Static methods | 366 | 15.86% |
▷ Public methods | 1,908 | 82.70% |
▷ Protected methods | 190 | 8.24% |
▷ Private methods | 209 | 9.06% |
Functions | 301 | |
▷ Named functions | 165 | 54.82% |
▷ Anonymous functions | 136 | 45.18% |
Constants | 134 | |
▷ Global constants | 14 | 10.45% |
▷ Class constants | 120 | 89.55% |
▷ Public constants | 120 | 100.00% |
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 |
assets/images/logo-256×256.png | 34.08KB | 8.68KB | ▼ 74.53% |
media/icon.png | 0.79KB | 0.66KB | ▼ 16.79% |