61% one-click-login

Code Review | One Click Login

WordPress plugin One Click Login scored 61% from 53 tests.

About plugin

  • Plugin page: one-click-login
  • Plugin version: 1.23.0
  • PHP compatiblity: 5.8+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.8
  • WordPress version: 5.8.1
  • First release: Oct 28, 2020
  • Latest release: Aug 18, 2021
  • Number of updates: 22
  • Update frequency: every 13.4 days
  • Top authors: bestpluginswordpress (100%)

Code review

53 tests

User reviews

1 review

Install metrics

10+ active / 388 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲5.36MB] [CPU: ▼232.34ms] 75% from 4 tests

Server-side resources used by One Click Login
It is recommended to improve the following
  • Extra RAM: Try to keep extra memory usage under 5MB (currently 5.36MB on /wp-admin/crb_carbon_fields_container_one_click_login.php)
PageMemory (MB)CPU Time (ms)
Home /8.54 ▲5.7057.03 ▲26.99
Dashboard /wp-admin8.55 ▲5.5079.80 ▲34.16
Posts /wp-admin/edit.php8.56 ▲5.4579.17 ▲33.61
Add New Post /wp-admin/post-new.php10.36 ▲4.93136.62 ▼1,013.18
Media Library /wp-admin/upload.php8.56 ▲5.5563.70 ▲23.22
Freemius Debug [v.2.4.2] /wp-admin/admin.php?page=freemius8.5664.48

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 1,196 new files
Database: no new tables, 4 new options
New WordPress options
fs_accounts
fs_gdpr
fs_debug_mode
fs_active_plugins

Browser metrics Passed 4 tests

One Click Login: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /4,075 ▲49320.67 ▲5.138.58 ▲0.8645.31 ▼4.34
Dashboard /wp-admin3,357 ▲50710.41 ▲4.44206.67 ▲76.47114.89 ▲0.55
Posts /wp-admin/edit.php3,133 ▲4276.74 ▲4.07110.35 ▲42.51102.00 ▲7.74
Add New Post /wp-admin/post-new.php1,760 ▼28219.44 ▲0.01306.05 ▼72.32115.23 ▲6.88
Media Library /wp-admin/upload.php1,906 ▲1317.17 ▲2.17139.04 ▼19.19117.76 ▲3.55
Freemius Debug [v.2.4.2] /wp-admin/admin.php?page=freemius1,8936.46109.0469.93
One Click Login /wp-admin/crb_carbon_fields_container_one_click_login.php260.900.229.51

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • The plugin did not uninstall gracefully
    • > Notice in wp-content/plugins/one-click-login/freemius/includes/class-freemius.php+8552
    Undefined property: stdClass::$plugins
  • This plugin did not uninstall successfully, leaving 4 options in the database
    • fs_debug_mode
    • fs_active_plugins
    • fs_accounts
    • fs_gdpr

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 0% 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
Please fix the following
  • 3× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/one-click-login/src/lib/carbon-fields3/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php
    • > /wp-content/plugins/one-click-login/freemius/templates/ajax-loader.php
    • > /wp-content/plugins/one-click-login/src/lib/carbon-fields2/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php
  • 430× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/one-click-login/src/lib/carbon-fields3/vendor/composer/installers/src/Composer/Installers/ChefInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/one-click-login/src/lib/carbon-fields2/vendor/composer/installers/src/Composer/Installers/BitrixInstaller.php:26
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Field\\Field' not found in wp-content/plugins/one-click-login/src/lib/carbon-fields3/vendor/htmlburger/carbon-fields/core/Field/Complex_Field.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Field\\Textarea_Field' not found in wp-content/plugins/one-click-login/src/lib/carbon-fields2/vendor/htmlburger/carbon-fields/core/Field/Rich_Text_Field.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/one-click-login/src/lib/carbon-fields2/vendor/composer/installers/src/Composer/Installers/FuelInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/one-click-login/src/lib/carbon-fields3/vendor/htmlburger/carbon-fields/templates/Container/comment_meta.php:1
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Condition\\Comparer\\Comparer' not found in wp-content/plugins/one-click-login/src/lib/carbon-fields2/vendor/htmlburger/carbon-fields/core/Container/Condition/Comparer/Custom_Comparer.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/one-click-login/src/lib/carbon-fields3/vendor/composer/installers/src/Composer/Installers/SiteDirectInstaller.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Field\\Field' not found in wp-content/plugins/one-click-login/src/lib/carbon-fields3/vendor/htmlburger/carbon-fields/core/Field/Oembed_Field.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function freemius() in wp-content/plugins/one-click-login/freemius/templates/partials/network-activation.php:6

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please take a look at the following user-side issues
    • > GET request to /wp-admin/crb_carbon_fields_container_one_click_login.php
    • > Network (severe)
    wp-admin/crb_carbon_fields_container_one_click_login.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 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
Attributes that require attention:
  • Tags: There are too many tags (17 tag instead of maximum 10)
The official readme.txt might help

one-click-login/plugin.php 92% from 13 tests

The main PHP file in "One Click Login" ver. 1.23.0 adds more information about the plugin and also serves as the entry point for this plugin
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("one-click-login.php" instead of "plugin.php")

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected138,045 lines of code in 915 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript31821,02535,71378,217
PHP43711,87927,43249,215
PO File351,9702,7514,701
CSS496181,2662,278
Sass4833401,746
JSON15001,240
Markdown91550597
YAML27027
XML12023
SVG1001

PHP code 50% from 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Please tend to the following items
  • Cyclomatic complexity of classes has to be reduced to less than 1000 (currently 2,907)
Cyclomatic complexity
Average complexity per logical line of code0.46
Average class complexity13.30
▷ Minimum class complexity1.00
▷ Maximum class complexity2,907.00
Average method complexity3.02
▷ Minimum method complexity1.00
▷ Maximum method complexity86.00
Code structure
Namespaces26
Interfaces10
Traits0
Classes488
▷ Abstract classes275.53%
▷ Concrete classes46194.47%
▷ Final classes20.43%
Methods3,130
▷ Static methods35511.34%
▷ Public methods2,33974.73%
▷ Protected methods40412.91%
▷ Private methods38712.36%
Functions317
▷ Named functions14044.16%
▷ Anonymous functions17755.84%
Constants188
▷ Global constants11259.57%
▷ Class constants7640.43%
▷ Public constants76100.00%

Plugin size Passed 1 test

Image compression Passed 1 test

Using a strong compression for your PNG files is a great way to speed-up your plugin
3 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
freemius/assets/img/one-click-login.png14.25KB6.77KB▼ 52.48%
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%