88% admin-color-schemer

Code Review | Admin Color Schemer

WordPress plugin Admin Color Schemer scored 88% from 54 tests.

About plugin

  • Plugin page: admin-color-schemer
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8+
  • WordPress version: 5.8.1
  • First release: Dec 24, 2013
  • Latest release: Oct 1, 2020
  • Number of updates: 11
  • Update frequency: every 228.5 days
  • Top authors: helen (90.91%)Otto42 (18.18%)

Code review

54 tests

User reviews

28 reviews

Install metrics

2,000+ active / 22,286 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.01MB] [CPU: ▼181.36ms] Passed 4 tests

A check of server-side resources used by Admin Color Schemer
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.0126.55 ▲4.34
Dashboard /wp-admin3.07 ▲0.0133.73 ▼6.89
Posts /wp-admin/edit.php3.13 ▲0.0231.81 ▼0.62
Add New Post /wp-admin/post-new.php5.44 ▼0.0067.53 ▼717.45
Media Library /wp-admin/upload.php3.02 ▲0.0122.53 ▼0.49
Admin Colors /wp-admin/tools.php?page=admin-color-schemer3.0420.33

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 62 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Admin Color Schemer
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,671 ▲7015.80 ▲0.284.98 ▼1.6976.47 ▼2.06
Dashboard /wp-admin2,935 ▲366.12 ▼0.04115.58 ▼19.48168.76 ▼6.45
Posts /wp-admin/edit.php2,742 ▲23.22 ▼0.0266.74 ▲0.10138.00 ▼2.78
Add New Post /wp-admin/post-new.php3,738 ▲1618.34 ▲0.24437.25 ▼14.66158.88 ▼2.45
Media Library /wp-admin/upload.php1,757 ▲55.52 ▲0.02141.19 ▼2.31185.68 ▲3.61
Admin Colors /wp-admin/tools.php?page=admin-color-schemer7,9625.40202.74112.04

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 0% from 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
Almost there! Just fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/admin-color-schemer/lib/phpsass/compile-apache.php
  • 27× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'SassNode' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/tree/SassReturnNode.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'SassRenderer' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/renderers/SassCompressedRenderer.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'SassNode' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/tree/SassContentNode.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'SassNode' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/tree/SassEachNode.php:25
    • > PHP Fatal error
      Uncaught Error: Class 'SassNode' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/tree/SassImportNode.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'SassNode' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/tree/SassCommentNode.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'SassIfNode' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/tree/SassElseNode.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'SassNode' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/tree/SassMediaNode.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'SassNode' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/tree/SassWhileNode.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'SassNode' not found in wp-content/plugins/admin-color-schemer/lib/phpsass/tree/SassMixinDefinitionNode.php:18

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
No plugin tags provided

admin-color-schemer/admin-color-schemer.php 92% from 13 tests

The main PHP file in "Admin Color Schemer" ver. 1.1 adds more information about the plugin and also serves as the entry point for this plugin
You should first fix the following items:
  • Domain Path: The domain path points to a folder that does not exist ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected5,477 lines of code in 60 files:
LanguageFilesBlank linesComment linesLines of code
PHP561,0493,8455,380
JSON10038
JavaScript16230
YAML10118
CSS12011

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity12.58
▷ Minimum class complexity1.00
▷ Maximum class complexity131.00
Average method complexity2.98
▷ Minimum method complexity1.00
▷ Maximum method complexity29.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes76
▷ Abstract classes11.32%
▷ Concrete classes7598.68%
▷ Final classes00.00%
Methods446
▷ Static methods10022.42%
▷ Public methods41091.93%
▷ Protected methods194.26%
▷ Private methods173.81%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants150
▷ Global constants00.00%
▷ Class constants150100.00%
▷ Public constants150100.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
PNG images were not found in this plugin