84% change-login-expiry

Code Review | Change Login Expiry

WordPress plugin Change Login Expiry scored 84% from 54 tests.

About plugin

  • Plugin page: change-login-expiry
  • Plugin version: 0.4.0
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-4.7
  • WordPress version: 6.3.1
  • First release: Jan 7, 2017
  • Latest release: Jan 7, 2017
  • Number of updates: 5
  • Update frequency: N/A
  • Top authors: ssiruguri (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 551 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.00MB] [CPU: ▼3.74ms] Passed 4 tests

Analyzing server-side resources used by Change Login Expiry
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0138.16 ▼2.63
Dashboard /wp-admin3.31 ▲0.0145.79 ▼6.39
Posts /wp-admin/edit.php3.36 ▲0.0047.20 ▲3.20
Add New Post /wp-admin/post-new.php5.89 ▲0.0097.71 ▼3.34
Media Library /wp-admin/upload.php3.23 ▲0.0033.75 ▼2.58

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

How much does this plugin use your filesystem and database?
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_recent-posts
widget_recent-comments
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Change Login Expiry
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲6813.27 ▼1.024.62 ▲2.7240.48 ▼3.42
Dashboard /wp-admin2,206 ▲184.85 ▼0.05107.55 ▲6.2642.09 ▲0.14
Posts /wp-admin/edit.php2,089 ▼02.16 ▲0.1041.10 ▲3.8037.50 ▲2.24
Add New Post /wp-admin/post-new.php1,514 ▼1917.90 ▼4.89641.52 ▼44.3067.74 ▲2.56
Media Library /wp-admin/upload.php1,382 ▼34.21 ▲0.0496.92 ▼15.0541.28 ▼10.86

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

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 fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/change-login-expiry/change_login_expiry.php:22

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
2 plugin tags: cookie expiry, login expiry

change-login-expiry/change_login_expiry.php 85% from 13 tests

"Change Login Expiry" version 0.4.0's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
You should first fix the following items:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("change-login-expiry.php" instead of "change_login_expiry.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected7 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP11147

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code1.00
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%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
PNG images were not found in this plugin