84% admin-users-logged-in

Code Review | Admin Users Logged In

WordPress plugin Admin Users Logged In scored84%from 54 tests.

About plugin

  • Plugin page: admin-users-logge...
  • Plugin version: 1.0.5
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.3
  • WordPress version: 6.3.1
  • First release: Feb 5, 2018
  • Latest release: Aug 7, 2023
  • Number of updates: 30
  • Update frequency: every 67.0 days
  • Top authors: mpol (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /2,002 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

Analyzing server-side resources used by Admin Users Logged In
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0038.80 ▼4.35
Dashboard /wp-admin3.32 ▲0.0151.98 ▲4.95
Posts /wp-admin/edit.php3.36 ▲0.0148.23 ▲6.62
Add New Post /wp-admin/post-new.php5.89 ▲0.0186.94 ▼9.45
Media Library /wp-admin/upload.php3.24 ▲0.0142.33 ▲9.35

Server storage [IO: ▲0.01MB] [DB: ▲0.07MB] Passed 3 tests

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Admin Users Logged In
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,850 ▲10413.21 ▼1.074.54 ▲2.6844.47 ▲0.14
Dashboard /wp-admin2,256 ▲685.88 ▲0.9797.54 ▼14.8540.46 ▼4.65
Posts /wp-admin/edit.php2,089 ▼02.01 ▼0.0536.32 ▼5.6232.78 ▼3.70
Add New Post /wp-admin/post-new.php1,535 ▲223.06 ▼0.27674.24 ▲48.7454.15 ▲5.52
Media Library /wp-admin/upload.php1,388 ▲34.18 ▲0.0396.84 ▼3.8543.70 ▲1.44

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 75% 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)
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/admin-users-logged-in/admin-users-logged-in.php

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 96% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
3 plugin tags: admin users, dashboard widget, last login

admin-users-logged-in/admin-users-logged-in.php 92% from 13 tests

Analyzing the main PHP file in "Admin Users Logged In" version 1.0.5
Please make the necessary changes and fix the following:
  • Domain Path: The domain path folder does not exist ("/lang/")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin92 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1306092

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.32
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%
Functions4
▷ Named functions4100.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
There were not PNG files found in your plugin