Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully
Server metrics [RAM: ▲0.02MB] [CPU: ▼4.82ms] Passed 4 tests
An overview of server-side resources used by face2 Two Factor Authentication
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.47 ▲0.01 | 44.83 ▲0.59 |
Dashboard /wp-admin | 3.32 ▲0.02 | 51.21 ▼5.25 |
Posts /wp-admin/edit.php | 3.38 ▲0.02 | 52.08 ▼2.40 |
Add New Post /wp-admin/post-new.php | 5.90 ▲0.02 | 86.77 ▼12.14 |
Media Library /wp-admin/upload.php | 3.25 ▲0.02 | 39.53 ▲0.53 |
face2 /wp-admin/options-general.php?page=face2 | 3.19 | 30.04 |
Server storage [IO: ▲1.80MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
This plugin was installed successfully
Filesystem: 21 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
widget_recent-posts |
can_compress_scripts |
db_upgraded |
theysaidso_admin_options |
widget_recent-comments |
Browser metrics Passed 4 tests
An overview of browser requirements for face2 Two Factor Authentication
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,793 ▲32 | 14.34 ▼0.00 | 1.72 ▲0.14 | 43.68 ▼1.34 |
Dashboard /wp-admin | 2,202 ▲25 | 5.58 ▼0.12 | 90.46 ▼3.46 | 45.49 ▲3.28 |
Posts /wp-admin/edit.php | 2,104 ▲4 | 2.02 ▼0.01 | 40.09 ▲0.19 | 35.52 ▼7.06 |
Add New Post /wp-admin/post-new.php | 1,529 ▲3 | 23.16 ▲0.16 | 599.76 ▼64.91 | 52.59 ▼4.81 |
Media Library /wp-admin/upload.php | 1,398 ▼2 | 4.19 ▼0.07 | 96.87 ▼14.42 | 43.42 ▼6.15 |
face2 /wp-admin/options-general.php?page=face2 | 915 | 2.12 | 22.84 | 29.53 |
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
These items require your attention
- Zombie WordPress options were found after uninstall: 6 options
- db_upgraded
- widget_theysaidso_widget
- widget_recent-posts
- theysaidso_admin_options
- can_compress_scripts
- widget_recent-comments
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
Almost there, just fix the following server-side errors
- > GET request to /wp-admin/options-general.php?page=face2
- > User deprecated in wp-includes/functions.php+5463
Function screen_icon is deprecated since version 3.8.0 with no alternative available.
- > GET request to /wp-admin/options-general.php?page=face2
- > User deprecated in wp-includes/functions.php+5463
Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
- 1× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function __() in wp-content/plugins/face2-face-recognition-based-two-factor-authentication/face2.php:161
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found
Optimizations
Plugin configuration 87% from 29 tests
readme.txt 88% from 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
- Tags: You are using too many tags: 11 tag instead of maximum 10
- Screenshots: These screenshots have no corresponding images in /assets: #1 (Form requesting face2 face (second factor) to complete login), #2 (Enabling two-factor authentication on user's profile)
face2-face-recognition-based-two-factor-authentication/face2.php 85% from 13 tests
Analyzing the main PHP file in "face2 Two Factor Authentication" version 1.0.1
You should first fix the following items:
- Main file name: Name the main plugin file the same as the plugin slug ("face2-face-recognition-based-two-factor-authentication.php" instead of "face2.php")
- Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
Code Analysis Passed 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
Good job! No executable or dangerous file extensions detected20,000 lines of code in 14 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 8 | 144 | 122 | 18,471 |
PHP | 3 | 530 | 824 | 1,455 |
CSS | 2 | 0 | 0 | 53 |
Markdown | 1 | 16 | 0 | 21 |
PHP code Passed 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.36 |
Average class complexity | 86.00 |
▷ Minimum class complexity | 11.00 |
▷ Maximum class complexity | 161.00 |
Average method complexity | 4.09 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 22.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 2 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 2 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 55 | |
▷ Static methods | 2 | 3.64% |
▷ Public methods | 43 | 78.18% |
▷ Protected methods | 8 | 14.55% |
▷ Private methods | 4 | 7.27% |
Functions | 13 | |
▷ Named functions | 13 | 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 50% from 2 tests
Image compression 50% from 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
5 PNG files occupy 0.90MB with 0.77MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/screenshot-2.png | 496.93KB | 68.47KB | ▼ 86.22% |
faceframe.png | 28.75KB | 1.16KB | ▼ 95.98% |
assets/screenshot-1.png | 333.80KB | 43.91KB | ▼ 86.85% |
allow.png | 64.20KB | 6.59KB | ▼ 89.73% |
assets/images/phone-icon.png | 1.11KB | 0.35KB | ▼ 68.68% |