84% daggerhart-openid-connect-generic

Code Review | OpenID Connect Generic Client

WordPress plugin OpenID Connect Generic Client scored84%from 54 tests.

About plugin

  • Plugin page: daggerhart-openid...
  • Plugin version: 3.9.1
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.0.1
  • WordPress version: 6.3.1
  • First release: Feb 25, 2018
  • Latest release: Aug 19, 2022
  • Number of updates: 18
  • Update frequency: every 92.8 days
  • Top authors: daggerhart (100%)

Code review

54 tests

User reviews

16 reviews

Install metrics

4,000+ active /62,963 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.06MB] [CPU: ▼4.69ms] Passed 4 tests

Analyzing server-side resources used by OpenID Connect Generic Client
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0336.00 ▼2.06
Dashboard /wp-admin3.38 ▲0.0747.41 ▼3.38
Posts /wp-admin/edit.php3.43 ▲0.0747.60 ▼3.96
Add New Post /wp-admin/post-new.php5.96 ▲0.0788.30 ▼9.34
Media Library /wp-admin/upload.php3.30 ▲0.0740.21 ▲4.84
OpenID Connect Client /wp-admin/options-general.php?page=openid-connect-generic-settings3.2631.67

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 14 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
db_upgraded
openid-connect-generic-plugin-version

Browser metrics Passed 4 tests

OpenID Connect Generic Client: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,799 ▲3814.30 ▲0.071.58 ▼0.3540.89 ▼4.62
Dashboard /wp-admin2,196 ▲195.54 ▼0.0383.57 ▼5.1643.15 ▼0.43
Posts /wp-admin/edit.php2,104 ▲41.99 ▲0.0336.26 ▲0.9133.80 ▼5.54
Add New Post /wp-admin/post-new.php1,530 ▼123.09 ▲0.02667.84 ▼4.6452.33 ▼0.54
Media Library /wp-admin/upload.php1,395 ▼84.27 ▲0.10101.91 ▼0.0945.58 ▲1.59
OpenID Connect Client /wp-admin/options-general.php?page=openid-connect-generic-settings1,2802.0022.1933.53

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
These items require your attention
  • The uninstall procedure has failed, leaving 7 options in the database
    • openid-connect-generic-plugin-version
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts

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)
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/daggerhart-openid-connect-generic/includes/openid-connect-generic-option-settings.php:119

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
8 plugin tags: sso, login, apps, openidconnect, autologin...

daggerhart-openid-connect-generic/openid-connect-generic.php 92% from 13 tests

Analyzing the main PHP file in "OpenID Connect Generic Client" version 3.9.1
Please take the time to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("daggerhart-openid-connect-generic.php" instead of "openid-connect-generic.php")

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
There were no executable files found in this plugin1,902 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
PHP84241,3211,667
Markdown1620130
YAML213578
CSS15027

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity38.14
▷ Minimum class complexity8.00
▷ Maximum class complexity138.00
Average method complexity3.68
▷ Minimum method complexity1.00
▷ Maximum method complexity29.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods97
▷ Static methods99.28%
▷ Public methods8789.69%
▷ Protected methods00.00%
▷ Private methods1010.31%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.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 are no PNG files in this plugin