84% one-time-login

Code Review | One Time Login

WordPress plugin One Time Login scored84%from 54 tests.

About plugin

  • Plugin page: one-time-login
  • Plugin version: 0.4.0
  • PHP compatiblity: 7.1+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-5.8
  • WordPress version: 6.3.1
  • First release: Apr 28, 2016
  • Latest release: May 16, 2023
  • Number of updates: 21
  • Update frequency: every 122.6 days
  • Top authors: danielbachhuber (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

20,000+ active /108,970 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.03MB] [CPU: ▼3.78ms] Passed 4 tests

This is a short check of server-side resources used by One Time Login
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0341.66 ▼3.02
Dashboard /wp-admin3.34 ▲0.0350.57 ▲0.46
Posts /wp-admin/edit.php3.39 ▲0.0348.10 ▼0.43
Add New Post /wp-admin/post-new.php5.92 ▲0.0387.40 ▼9.91
Media Library /wp-admin/upload.php3.26 ▲0.0333.03 ▼1.77

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for One Time Login
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.25 ▼1.221.80 ▼0.0143.03 ▼2.02
Dashboard /wp-admin2,209 ▲184.85 ▼0.03106.31 ▲2.2443.70 ▼0.63
Posts /wp-admin/edit.php2,092 ▲32.03 ▲0.0134.76 ▼2.2532.68 ▼1.16
Add New Post /wp-admin/post-new.php1,539 ▲623.10 ▼0.05652.00 ▼16.4350.03 ▼4.89
Media Library /wp-admin/upload.php1,388 ▲64.18 ▼0.0395.87 ▼3.2742.93 ▲0.42

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

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 take a closer look at the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/one-time-login/one-time-login.php:161

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
1 plugin tags: login

one-time-login/one-time-login.php 92% from 13 tests

Analyzing the main PHP file in "One Time Login" version 0.4.0
The following require your attention:
  • Domain Path: The domain path is invalid: folder "/languages" does not exist

Code Analysis Passed 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
Everything looks great! No dangerous files found in this plugin152 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP12574152

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.40
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%
Functions9
▷ Named functions666.67%
▷ Anonymous functions333.33%
Constants1
▷ Global constants1100.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
PNG images were not found in this plugin