84% lh-number-user-nicename

Code Review | = LH Number User Nicename

WordPress plugin = LH Number User Nicename scored84%from 54 tests.

About plugin

  • Plugin page: lh-number-user-ni...
  • Plugin version: 1.06
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.0
  • WordPress version: 6.3.1
  • First release: Mar 9, 2017
  • Latest release: Jul 31, 2022
  • Number of updates: 7
  • Update frequency: every 280.4 days
  • Top authors: shawfactor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /628 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.05MB] [CPU: ▼8.93ms] Passed 4 tests

Analyzing server-side resources used by = LH Number User Nicename
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0638.03 ▼11.93
Dashboard /wp-admin3.35 ▲0.0544.21 ▼4.10
Posts /wp-admin/edit.php3.46 ▲0.1144.01 ▼3.19
Add New Post /wp-admin/post-new.php5.93 ▲0.0482.70 ▼16.50
Media Library /wp-admin/upload.php3.27 ▲0.0433.92 ▼2.12

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

= LH Number User Nicename: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲6813.26 ▼1.111.84 ▼0.2940.62 ▼4.69
Dashboard /wp-admin2,203 ▲154.87 ▼0.01103.41 ▼14.2938.91 ▼10.03
Posts /wp-admin/edit.php2,086 ▼31.99 ▼0.0132.97 ▼4.9229.70 ▼5.58
Add New Post /wp-admin/post-new.php1,519 ▲523.43 ▲5.94646.79 ▼44.3961.20 ▲15.33
Media Library /wp-admin/upload.php1,391 ▲34.14 ▼0.0497.68 ▲4.0143.44 ▼0.38

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
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded

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 everything seems fine, this is not 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
Almost there! Just fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/lh-number-user-nicename/lh-number-user-nicename.php:305

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

Often overlooked, readme.txt is one of the most important files in your plugin
5 plugin tags: url, author, number, security, nicename

lh-number-user-nicename/lh-number-user-nicename.php 92% from 13 tests

"= LH Number User Nicename" version 1.06's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Text Domain: The text domain should only use lowercase characters and dashes

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin154 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP213629154

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity21.00
▷ Minimum class complexity21.00
▷ Maximum class complexity21.00
Average method complexity2.05
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods19
▷ Static methods1157.89%
▷ Public methods19100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
No PNG images were found in this plugin