84% wp-custom-login-branding

Code Review | WP Custom Login Branding

WordPress plugin WP Custom Login Branding scored84%from 54 tests.

About plugin

  • Plugin page: wp-custom-login-b...
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0.0-5.4
  • WordPress version: 6.3.1
  • First release: Jul 13, 2016
  • Latest release: Apr 27, 2020
  • Number of updates: 28
  • Update frequency: every 49.4 days
  • Top authors: 2cloud (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

300+ active /2,900 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 gracefully, with no errors

Server metrics [RAM: ▲0.09MB] [CPU: ▼3.89ms] Passed 4 tests

This is a short check of server-side resources used by WP Custom Login Branding
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0644.68 ▲1.82
Dashboard /wp-admin3.42 ▲0.1155.16 ▼0.92
Posts /wp-admin/edit.php3.54 ▲0.1753.08 ▲2.88
Add New Post /wp-admin/post-new.php6.00 ▲0.1185.29 ▼19.33
Media Library /wp-admin/upload.php3.32 ▲0.0941.88 ▲6.51
Custom Login /wp-admin/options-general.php?page=custom-login-settings3.3239.72

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
db_upgraded
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for WP Custom Login Branding
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,949 ▲18814.79 ▲0.441.76 ▲0.1144.06 ▼4.72
Dashboard /wp-admin2,358 ▲1816.38 ▲0.72111.21 ▲8.0041.91 ▼3.55
Posts /wp-admin/edit.php2,283 ▲1833.53 ▲1.5452.21 ▲13.1130.80 ▼3.84
Add New Post /wp-admin/post-new.php1,701 ▲17322.31 ▼1.03657.26 ▼4.2637.96 ▼17.21
Media Library /wp-admin/upload.php1,423 ▲234.38 ▲0.1984.70 ▼20.8945.69 ▼0.93
Custom Login /wp-admin/options-general.php?page=custom-login-settings1,7414.2978.2830.66

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting 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
Almost there! Just fix the following items
  • 3× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/wp-custom-login-branding/inc/wclbsettings.class.php:404
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_die() in wp-content/plugins/wp-custom-login-branding/wp-custom-login-branding.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/wp-custom-login-branding/inc/wpcustombranding.class.php:19

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 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Screenshots: These screenshots require images: #1 (Admin Interface), #2 (Example of styled login screen)
Please take inspiration from this readme.txt

wp-custom-login-branding/wp-custom-login-branding.php Passed 13 tests

The principal PHP file in "WP Custom Login Branding" v. 1.3 is loaded by WordPress automatically on each request
75 characters long description:
Simple plugin for developers / designers who want to brand WP login screen.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected477 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP312723421
JavaScript141329
Markdown117027

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity21.00
▷ Minimum class complexity9.00
▷ Maximum class complexity33.00
Average method complexity2.43
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods28
▷ Static methods00.00%
▷ Public methods28100.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

Using a strong compression for your PNG files is a great way to speed-up your plugin
2 PNG files occupy 0.12MB with 0.08MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png54.58KB12.42KB▼ 77.24%
screenshot-1.png66.67KB29.61KB▼ 55.60%