94% users-profile-navigation

Code Review | Users Profile Navigation

WordPress plugin Users Profile Navigation scored 94% from 54 tests.

About plugin

  • Plugin page: users-profile-nav...
  • Plugin version: 0.9.7
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-4.7.3
  • WordPress version: 5.8.1
  • First release: Mar 16, 2017
  • Latest release: Mar 24, 2017
  • Number of updates: 8
  • Update frequency: every 0.5 days
  • Top authors: sanya1917 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 369 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

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

Analyzing server-side resources used by Users Profile Navigation
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.1234.41 ▲7.72
Dashboard /wp-admin3.07 ▲0.0143.32 ▼0.19
Posts /wp-admin/edit.php3.13 ▲0.0141.56 ▲3.93
Add New Post /wp-admin/post-new.php5.43 ▼0.0187.13 ▼561.03
Media Library /wp-admin/upload.php3.02 ▲0.0129.07 ▼5.63

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 11 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

A check of browser resources used by Users Profile Navigation
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,681 ▲8516.21 ▲0.618.73 ▲0.2847.12 ▼1.75
Dashboard /wp-admin2,968 ▲376.08 ▲0.11150.41 ▲10.28113.29 ▲3.46
Posts /wp-admin/edit.php2,741 ▲22.71 ▼0.0165.75 ▲0.9891.33 ▲2.46
Add New Post /wp-admin/post-new.php1,693 ▲2118.79 ▼0.37365.88 ▼24.77106.41 ▲0.32
Media Library /wp-admin/upload.php1,812 ▲55.02 ▼0.01139.76 ▼8.67119.10 ▲1.53

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Uninstaller ran successfully

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)
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Hdi\\Users_Profile_Navigation\\Controllers\\add_action() in wp-content/plugins/users-profile-navigation/include/class-users-profile-navigation-main.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function Hdi\\Users_Profile_Navigation\\Controllers\\add_action() in wp-content/plugins/users-profile-navigation/include/class-users-profile-navigation-main.php:9

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
4 plugin tags: navigation, user, administration, profile

users-profile-navigation/users-profile-navigation.php Passed 13 tests

The main PHP file in "Users Profile Navigation" ver. 0.9.7 adds more information about the plugin and also serves as the entry point for this plugin
25 characters long description:
Users profile navigation.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected155 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP42122110
PO File15632
CSS12011
Markdown1002

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.07
Average class complexity2.00
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.33
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces4
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods777.78%
▷ Protected methods00.00%
▷ Private methods222.22%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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 files were detected