83% show-visitor-ip

Code Review | Show Visitor IP

WordPress plugin Show Visitor IP scored 83% from 54 tests.

About plugin

  • Plugin page: show-visitor-ip
  • Plugin version: 5.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-6.3
  • WordPress version: 6.3.1
  • First release: Aug 29, 2017
  • Latest release: Sep 30, 2023
  • Number of updates: 14
  • Update frequency: every 159.1 days
  • Top authors: devikas301 (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

600+ active / 5,760 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.01MB] [CPU: ▼0.82ms] Passed 4 tests

Analyzing server-side resources used by Show Visitor IP
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.81 ▼3.56
Dashboard /wp-admin3.32 ▲0.0149.45 ▲2.66
Posts /wp-admin/edit.php3.37 ▲0.0143.82 ▲0.65
Add New Post /wp-admin/post-new.php5.90 ▲0.0186.51 ▲1.67
Media Library /wp-admin/upload.php3.24 ▲0.0133.37 ▼2.05

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Show Visitor IP
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.26 ▼1.491.74 ▼0.5544.21 ▼6.18
Dashboard /wp-admin2,206 ▲185.86 ▲0.0596.39 ▼11.2741.04 ▼3.11
Posts /wp-admin/edit.php2,089 ▲32.02 ▲0.0332.88 ▼4.1833.38 ▼2.72
Add New Post /wp-admin/post-new.php1,546 ▲3223.02 ▲5.56638.80 ▼72.0767.89 ▲13.88
Media Library /wp-admin/upload.php1,382 ▼94.24 ▲0.0997.83 ▼9.9640.27 ▼4.79

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • 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
Everything seems fine, however this is by no means an exhaustive test

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
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/show-visitor-ip/show-visitor-ip.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Screenshots: Add images for these screenshots: #1 (screenshot page "Add New Post" with shortcode), #2 (screenshot page "Public Post" with user IP Address & another user location info.)
  • Tags: You are using too many tags: 13 tag instead of maximum 10
You can look at the official readme.txt

show-visitor-ip/show-visitor-ip.php 92% from 13 tests

This is the main PHP file of "Show Visitor IP" version 5.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 221 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Success! There were no dangerous files found in this plugin55 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP28955

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.50
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png18.06KB5.17KB▼ 71.36%
screenshot-1.png30.95KB10.62KB▼ 65.70%