83% dark-login-screen

Code Review | Dark Login Screen

WordPress plugin Dark Login Screen scored83%from 54 tests.

About plugin

  • Plugin page: dark-login-screen
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.9
  • WordPress version: 6.3.1
  • First release: Jun 17, 2014
  • Latest release: Jun 17, 2014
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: silver530 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,209 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
This plugin's installer ran successfully

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

An overview of server-side resources used by Dark Login Screen
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0042.98 ▼9.27
Dashboard /wp-admin3.31 ▲0.0150.51 ▲0.51
Posts /wp-admin/edit.php3.36 ▲0.0050.55 ▼9.77
Add New Post /wp-admin/post-new.php5.89 ▲0.0087.69 ▼19.91
Media Library /wp-admin/upload.php3.23 ▲0.0035.43 ▲0.71

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Dark Login Screen
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,828 ▲8213.14 ▼1.412.04 ▲0.2940.24 ▲0.13
Dashboard /wp-admin2,209 ▲214.85 ▼0.0499.31 ▼11.8339.70 ▼3.33
Posts /wp-admin/edit.php2,089 ▼02.00 ▼0.0541.48 ▲0.1534.80 ▼2.42
Add New Post /wp-admin/post-new.php1,528 ▼523.13 ▼0.02678.59 ▲48.7964.53 ▲8.23
Media Library /wp-admin/upload.php1,388 ▲34.23 ▲0.01107.84 ▲6.9245.94 ▼1.69

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
  • Zombie WordPress options detected upon uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

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)
The smoke test was a success, however most plugin functionality was not tested

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 server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/dark-login-screen/dark-login-screen.php:41

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that require attention:
  • Tags: Please delete some tags, you are using 35 tag instead of maximum 10
  • Screenshots: Please add an image for screenshot #1 (screenshot-1.png)
You can look at the official readme.txt

dark-login-screen/dark-login-screen.php 92% from 13 tests

The main PHP script in "Dark Login Screen" version 1.0 is automatically included on every request by WordPress
The following require your attention:
  • Text Domain: The text domain follows the same naming rules as the plugin slug: lowercase characters and dashes

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
Everything looks great! No dangerous files found in this plugin155 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PO File42872132
PHP2172923

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.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%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
1 PNG file occupies 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png11.18KB5.49KB▼ 50.90%