74% visitors-details

Code Review | Visitor Details

WordPress plugin Visitor Details scored74%from 54 tests.

About plugin

  • Plugin page: visitors-details
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.1-5.9
  • WordPress version: 6.3.1
  • First release: Jan 20, 2020
  • Latest release: Jan 31, 2022
  • Number of updates: 8
  • Update frequency: every 93.1 days
  • Top authors: ravisinghit (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

200+ active /1,537 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.08MB] [CPU: ▼0.96ms] Passed 4 tests

Analyzing server-side resources used by Visitor Details
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1150.37 ▲11.47
Dashboard /wp-admin3.36 ▲0.0647.42 ▼6.28
Posts /wp-admin/edit.php3.51 ▲0.1548.60 ▼2.82
Add New Post /wp-admin/post-new.php5.96 ▲0.0895.49 ▲2.30
Media Library /wp-admin/upload.php3.29 ▲0.0636.42 ▲2.97
Visitors Details /wp-admin/options-general.php?page=visitors-details3.2633.05

Server storage [IO: ▲0.15MB] [DB: ▲0.00MB] Passed 3 tests

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 31 new files
Database: 1 new table, 7 new options
New tables
wp_visitordetails
New WordPress options
can_compress_scripts
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
wvd_db_version
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Visitor Details
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,894 ▲15913.95 ▼0.455.84 ▲4.0638.67 ▼9.66
Dashboard /wp-admin2,214 ▲295.23 ▼0.62112.53 ▼4.0942.40 ▼3.47
Posts /wp-admin/edit.php2,103 ▲142.34 ▲0.3441.15 ▲1.8934.42 ▼3.03
Add New Post /wp-admin/post-new.php1,524 ▲1023.25 ▲5.63643.67 ▼38.8572.20 ▲17.24
Media Library /wp-admin/upload.php1,399 ▲174.45 ▲0.2296.14 ▼0.5642.10 ▼5.81
Visitors Details /wp-admin/options-general.php?page=visitors-details9972.4943.0031.01

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • This plugin does not fully uninstall, leaving 1 table in the database
    • wp_visitordetails
  • Zombie WordPress options were found after uninstall: 7 options
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • wvd_db_version
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following items
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/visitors-details/public/partials/wp-visitors-details-public-display.php
    • > /wp-content/plugins/visitors-details/admin/partials/wp-visitors-details-admin-display.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
5 plugin tags: user-detail, user-visit, ip-address, visitor-details, active-user

visitors-details/visitors-details.php 92% from 13 tests

The main PHP script in "Visitor Details" version 1.0.1 is automatically included on every request by WordPress
You should first fix the following items:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 182 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected590 lines of code in 20 files:
LanguageFilesBlank linesComment linesLines of code
PHP13159527418
JavaScript3231170
CSS4082

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity4.12
▷ Minimum class complexity1.00
▷ Maximum class complexity23.00
Average method complexity1.89
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods28
▷ Static methods725.00%
▷ Public methods2278.57%
▷ Protected methods00.00%
▷ Private methods621.43%
Functions7
▷ Named functions7100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
5 compressed PNG files occupy 0.00MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/images/sort_both.png0.20KB0.29KB0.00%
admin/images/sort_desc.png0.15KB0.25KB0.00%
admin/images/sort_asc.png0.16KB0.25KB0.00%
admin/images/sort_desc_disabled.png0.14KB0.25KB0.00%
admin/images/sort_asc_disabled.png0.14KB0.25KB0.00%