84% logged-in-as

Code Review | Logged In As

WordPress plugin Logged In As scored84%from 54 tests.

About plugin

  • Plugin page: logged-in-as
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.9.3
  • WordPress version: 6.3.1
  • First release: Apr 24, 2020
  • Latest release: Apr 25, 2022
  • Number of updates: 8
  • Update frequency: every 91.5 days
  • Top authors: jerrystewart99 (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

200+ active /1,884 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.08MB] [CPU: ▼3.63ms] Passed 4 tests

An overview of server-side resources used by Logged In As
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0735.16 ▼3.90
Dashboard /wp-admin3.38 ▲0.0842.58 ▼4.93
Posts /wp-admin/edit.php3.49 ▲0.1442.31 ▼5.42
Add New Post /wp-admin/post-new.php5.96 ▲0.0890.29 ▲1.34
Media Library /wp-admin/upload.php3.30 ▲0.0832.70 ▼0.25
Logged In As /wp-admin/options-general.php?page=logged-in-as3.2731.23

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Logged In As
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,795 ▲3414.28 ▼0.061.67 ▼0.0438.06 ▼6.20
Dashboard /wp-admin2,196 ▲285.55 ▼0.0283.73 ▼15.0639.39 ▼9.04
Posts /wp-admin/edit.php2,104 ▲42.03 ▲0.0234.41 ▼4.8935.50 ▼3.45
Add New Post /wp-admin/post-new.php1,534 ▲622.72 ▼0.47615.09 ▼60.5358.53 ▼3.30
Media Library /wp-admin/upload.php1,404 ▲44.18 ▲0.0496.84 ▼2.6442.74 ▼0.51
Logged In As /wp-admin/options-general.php?page=logged-in-as8722.0221.7625.27

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

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

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 no errors were found, this is by no means 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
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function logged_in_as\\add_action() in wp-content/plugins/logged-in-as/includes/lia-css.php:8

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
6 plugin tags: members, menu, ultimate member, logged in, membership...

logged-in-as/logged-in-as.php 92% from 13 tests

The entry point to "Logged In As" version 1.0.0 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 145 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Good job! No executable or dangerous file extensions detected294 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP4158168294

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity9.00
▷ Minimum class complexity9.00
▷ Maximum class complexity9.00
Average method complexity1.94
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods18
▷ Static methods00.00%
▷ Public methods1794.44%
▷ Protected methods00.00%
▷ Private methods15.56%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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
No PNG images were found in this plugin