80% blinds

Code Review | Blinds Dark Mode

WordPress plugin Blinds Dark Mode scored 80% from 54 tests.

About plugin

  • Plugin page: blinds
  • Plugin version: 0.0.7
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.5
  • WordPress version: 6.3.1
  • First release: Sep 23, 2020
  • Latest release: Sep 28, 2020
  • Number of updates: 15
  • Update frequency: every 0.3 days
  • Top authors: ikennaf1 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 928 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▼1.96MB] [CPU: ▼51.08ms] Passed 4 tests

This is a short check of server-side resources used by Blinds Dark Mode
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.433.96 ▼32.29
Dashboard /wp-admin2.05 ▼1.267.97 ▼36.29
Posts /wp-admin/edit.php2.05 ▼1.315.72 ▼42.02
Add New Post /wp-admin/post-new.php2.05 ▼3.846.38 ▼93.72
Media Library /wp-admin/upload.php2.05 ▼1.185.25 ▼26.43

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Blinds Dark Mode
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,853 ▲11813.64 ▼0.763.24 ▲1.6240.95 ▼9.81
Dashboard /wp-admin2,215 ▲304.91 ▼0.12109.94 ▼5.8541.10 ▼3.50
Posts /wp-admin/edit.php2,104 ▲182.01 ▼0.0241.17 ▲1.5234.70 ▼0.89
Add New Post /wp-admin/post-new.php1,376 ▼13820.35 ▲2.80550.73 ▼57.5945.79 ▼4.53
Media Library /wp-admin/upload.php1,394 ▲64.13 ▼0.06100.01 ▼0.7842.62 ▼1.80

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • Uninstall procedure validation failed for this plugin
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the blinds.js handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP Passed 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
6 plugin tags: night-mode, night mode, dark-mode, nightmode, darkmode...

blinds/blinds.php Passed 13 tests

The entry point to "Blinds Dark Mode" version 0.0.7 is a PHP file that has certain tags in its header comment area
86 characters long description:
A plugin that enables WordPress end users view a blog or website in night or dark mode

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Good job! No executable or dangerous file extensions detected204 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript11235157
PHP2132647

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.38
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There are no PNG files in this plugin