84% admin-customizer

Code Review | Admin Customizer

WordPress plugin Admin Customizer scored84%from 54 tests.

About plugin

  • Plugin page: admin-customizer
  • Plugin version: 2.2.7
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.3
  • WordPress version: 6.3.1
  • First release: Nov 4, 2013
  • Latest release: Aug 15, 2023
  • Number of updates: 78
  • Update frequency: every 45.8 days
  • Top authors: rabmalin (100%)

Code review

54 tests

User reviews

14 reviews

Install metrics

2,000+ active /30,097 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.47MB] [CPU: ▼0.04ms] Passed 4 tests

This is a short check of server-side resources used by Admin Customizer
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.86 ▲0.3938.52 ▼4.18
Dashboard /wp-admin3.81 ▲0.5146.76 ▼4.33
Posts /wp-admin/edit.php3.85 ▲0.5048.77 ▲1.56
Add New Post /wp-admin/post-new.php6.38 ▲0.5098.64 ▲7.49
Media Library /wp-admin/upload.php3.73 ▲0.5039.38 ▲6.80
Admin Customizer /wp-admin/options-general.php?page=admin-customizer3.7939.96

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Admin Customizer
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,521 ▼22514.25 ▼0.391.76 ▼0.3342.72 ▼4.54
Dashboard /wp-admin1,969 ▼2055.60 ▼0.3089.12 ▼25.2036.78 ▼9.50
Posts /wp-admin/edit.php2,017 ▼722.03 ▲0.0239.61 ▲2.3230.45 ▼3.68
Add New Post /wp-admin/post-new.php1,483 ▼5923.23 ▲4.89644.71 ▼7.8164.57 ▲13.89
Media Library /wp-admin/upload.php1,313 ▼754.21 ▲0.0198.83 ▲2.1539.80 ▼4.62
Admin Customizer /wp-admin/options-general.php?page=admin-customizer2,2238.24187.6040.37

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 75% from 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 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 125× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Warning
      include_once(): Failed opening 'ADMIN_CUSTOMIZER_PLUGIN_URI/npf-framework/fields/textarea.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/admin-customizer/npf-framework/init.php on line 41
    • > PHP Warning
      include_once(): Failed opening 'ADMIN_CUSTOMIZER_PLUGIN_URI/npf-framework/fields/custom_taxonomy_checkbox.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/admin-customizer/npf-framework/init.php on line 41
    • > PHP Fatal error
      Uncaught Error: Class 'npf_field' not found in wp-content/plugins/admin-customizer/npf-framework/fields/email.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'npf_field' not found in wp-content/plugins/admin-customizer/npf-framework/fields/textarea.php:3
    • > PHP Warning
      include_once(ADMIN_CUSTOMIZER_PLUGIN_URI/npf-framework/fields/time.php): failed to open stream: No such file or directory in wp-content/plugins/admin-customizer/npf-framework/init.php on line 41
    • > PHP Fatal error
      Uncaught Error: Class 'npf_field' not found in wp-content/plugins/admin-customizer/npf-framework/fields/upload.php:3
    • > PHP Warning
      Use of undefined constant ADMIN_CUSTOMIZER_PLUGIN_URI - assumed 'ADMIN_CUSTOMIZER_PLUGIN_URI' (this will throw an Error in a future version of PHP) in wp-content/plugins/admin-customizer/npf-framework/init.php on line 41
    • > PHP Warning
      include_once(): Failed opening 'ADMIN_CUSTOMIZER_PLUGIN_URI/npf-framework/fields/sidebar_select.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/admin-customizer/npf-framework/init.php on line 41
    • > PHP Warning
      include_once(): Failed opening 'ADMIN_CUSTOMIZER_PLUGIN_URI/npf-framework/fields/custom_css.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/admin-customizer/npf-framework/init.php on line 41
    • > PHP Warning
      include_once(): Failed opening 'ADMIN_CUSTOMIZER_PLUGIN_URI/npf-framework/fields/_base.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/admin-customizer/npf-framework/init.php on line 41

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that need to be fixed:
  • Tags: Please reduce the number of tags, currently 28 tag instead of maximum 10
You can take inspiration from this readme.txt

admin-customizer/admin-customizer.php Passed 13 tests

The primary PHP file in "Admin Customizer" version 2.2.7 is used by WordPress to initiate all plugin functionality
79 characters long description:
This plugin allows you to customize the admin interface of your WordPress site.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected5,275 lines of code in 64 files:
LanguageFilesBlank linesComment linesLines of code
PHP475848952,523
JavaScript92463531,851
CSS616125818
JSON20083

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity8.34
▷ Minimum class complexity1.00
▷ Maximum class complexity47.00
Average method complexity2.81
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes38
▷ Abstract classes00.00%
▷ Concrete classes38100.00%
▷ Final classes00.00%
Methods155
▷ Static methods2012.90%
▷ Public methods13989.68%
▷ Protected methods95.81%
▷ Private methods74.52%
Functions5
▷ Named functions480.00%
▷ Anonymous functions120.00%
Constants7
▷ Global constants7100.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
4 compressed PNG files occupy 0.01MB
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
npf-framework/assets/images/checks.png0.66KB0.65KB▼ 0.60%
npf-framework/assets/vendor/select2/select2x2.png0.83KB0.77KB▼ 6.15%
npf-framework/assets/vendor/select2/select2.png0.60KB0.99KB0.00%
npf-framework/assets/vendor/tzcheckbox/background.png4.96KB2.59KB▼ 47.82%