84% limit-login-attempts-plus

Code Review | Limit Login Attempts Plus - WordPress Limit Login Attempts By Felix

WordPress plugin Limit Login Attempts Plus - WordPress Limit Login Attempts By Felix scored84%from 54 tests.

About plugin

  • Plugin page: limit-login-attem...
  • Plugin version: 1.1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-6.1.1
  • WordPress version: 6.3.1
  • First release: Sep 23, 2020
  • Latest release: Jan 26, 2023
  • Number of updates: 60
  • Update frequency: every 14.3 days
  • Top authors: devfelixmoira (100%)

Code review

54 tests

User reviews

1 review

Install metrics

600+ active /7,644 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

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

An overview of server-side resources used by Limit Login Attempts Plus - WordPress Limit Login Attempts By Felix
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0444.45 ▲2.73
Dashboard /wp-admin3.34 ▲0.0356.39 ▲0.87
Posts /wp-admin/edit.php3.45 ▲0.0953.52 ▲1.64
Add New Post /wp-admin/post-new.php5.92 ▲0.0391.20 ▼4.41
Media Library /wp-admin/upload.php3.26 ▲0.0337.16 ▼1.21

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Limit Login Attempts Plus - WordPress Limit Login Attempts By Felix
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲5414.28 ▼0.281.98 ▼0.3545.37 ▼0.88
Dashboard /wp-admin2,224 ▲475.56 ▼0.1190.42 ▼7.8869.93 ▲25.95
Posts /wp-admin/edit.php2,129 ▲262.03 ▲0.0236.37 ▲0.7334.93 ▲0.13
Add New Post /wp-admin/post-new.php1,546 ▲2023.03 ▼0.63784.03 ▲36.4249.14 ▼1.53
Media Library /wp-admin/upload.php1,417 ▲174.13 ▼0.05107.04 ▲6.3877.60 ▲27.39

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
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/limit-login-attempts-plus/limit-login-attempts-plus.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need your attention:
  • Contributors: The plugin contributors field is not present
  • Tags: Please reduce the number of tags, currently 11 tag instead of maximum 10
The official readme.txt might help

limit-login-attempts-plus/limit-login-attempts-plus.php Passed 13 tests

The primary PHP file in "Limit Login Attempts Plus - WordPress Limit Login Attempts By Felix" version 1.1.0 is used by WordPress to initiate all plugin functionality
86 characters long description:
Limit the rate of login attempts, including by way of cookies and for each IP address.

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
Good job! No executable or dangerous file extensions detected3,794 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
PO File171,0301,3152,695
PHP52863171,058
Sass11024
CSS11011
JavaScript1305
SVG1001

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.56
Average class complexity76.67
▷ Minimum class complexity2.00
▷ Maximum class complexity219.00
Average method complexity5.54
▷ Minimum method complexity1.00
▷ Maximum method complexity29.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods50
▷ Static methods36.00%
▷ Public methods4794.00%
▷ Protected methods00.00%
▷ Private methods36.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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
PNG images were not found in this plugin