78% wp-admin-ui

Code Review | WP Admin UI

WordPress plugin WP Admin UI scored78%from 54 tests.

About plugin

  • Plugin page: wp-admin-ui
  • Plugin version: 1.9.10
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: May 5, 2015
  • Latest release: Aug 15, 2019
  • Number of updates: 106
  • Update frequency: every 14.8 days
  • Top authors: rainbowgeek (100%)

Code review

54 tests

User reviews

22 reviews

Install metrics

2,000+ active /63,063 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.72MB] [CPU: ▼0.26ms] Passed 4 tests

Analyzing server-side resources used by WP Admin UI
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0844.51 ▲0.10
Dashboard /wp-admin4.28 ▲0.9756.76 ▲3.48
Posts /wp-admin/edit.php4.33 ▲0.9758.55 ▲6.07
Add New Post /wp-admin/post-new.php6.79 ▲0.9194.19 ▼7.94
Media Library /wp-admin/upload.php4.14 ▲0.9145.44 ▲3.34
Global /wp-admin/admin.php?page=wpui-global4.0839.01
Login /wp-admin/admin.php?page=wpui-login4.0840.86
Dashboard /wp-admin/admin.php?page=wpui-dashboard4.0836.56
Role Manager /wp-admin/admin.php?page=wpui-roles4.1045.17
Admin Menu /wp-admin/admin.php?page=wpui-admin-menu4.1042.74
Media Library /wp-admin/admin.php?page=wpui-library4.0837.64
Import / Export / Reset /wp-admin/admin.php?page=wpui-import-export4.1136.82
Admin Bar /wp-admin/admin.php?page=wpui-admin-bar4.0836.67
Editor /wp-admin/admin.php?page=wpui-editor4.0838.29
Profile /wp-admin/admin.php?page=wpui-profil4.1143.38

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 78 new files
Database: no new tables, 9 new options
New WordPress options
wpui_activated
wpui_admin_menu_slug
wpui_admin_menu_default_option_name
db_upgraded
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

WP Admin UI: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,932 ▲17114.78 ▲0.231.91 ▼0.0843.79 ▼0.36
Dashboard /wp-admin2,335 ▲1615.79 ▲0.1892.47 ▼7.0239.53 ▼5.25
Posts /wp-admin/edit.php2,243 ▲1402.31 ▲0.3147.50 ▲10.8638.02 ▼1.71
Add New Post /wp-admin/post-new.php1,618 ▲9023.37 ▲0.46697.35 ▲17.2769.71 ▲8.81
Media Library /wp-admin/upload.php1,540 ▲1404.28 ▲0.07106.06 ▼3.3542.21 ▼4.40
Global /wp-admin/admin.php?page=wpui-global1,1982.0242.9228.68
Login /wp-admin/admin.php?page=wpui-login1,0321.8332.0331.35
Dashboard /wp-admin/admin.php?page=wpui-dashboard1,6326.42127.6855.76
Role Manager /wp-admin/admin.php?page=wpui-roles4,2361.8736.5045.88
Admin Menu /wp-admin/admin.php?page=wpui-admin-menu1,8482.5269.7445.40
Media Library /wp-admin/admin.php?page=wpui-library1,0872.0941.7429.01
Import / Export / Reset /wp-admin/admin.php?page=wpui-import-export1,0331.9336.6030.76
Admin Bar /wp-admin/admin.php?page=wpui-admin-bar1,0621.9838.0531.27
Editor /wp-admin/admin.php?page=wpui-editor1,1951.8331.5831.12
Profile /wp-admin/admin.php?page=wpui-profil1,1021.8333.1130.91

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
The following items require your attention
  • The uninstall procedure has failed, leaving 8 options in the database
    • wpui_admin_menu_slug
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • wpui_admin_menu_default_option_name
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These server-side errors were triggered
  • 32 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpui-editor
    • > Notice in wp-content/plugins/wp-admin-ui/inc/admin/admin.php+3440
    Trying to access array offset on value of type bool
  • 24 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=wpui-admin-menu
    • > Notice in wp-content/plugins/wp-admin-ui/inc/admin/admin.php+2697
    Trying to access array offset on value of type null

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
Please fix the following items
  • 16× PHP files perform the action of outputting non-empty strings when accessed directly (only 10 are shown):
    • > /wp-content/plugins/wp-admin-ui/inc/functions/options-front.php
    • > /wp-content/plugins/wp-admin-ui/inc/functions/options-admin-bar.php
    • > /wp-content/plugins/wp-admin-ui/inc/admin/adminbar.php
    • > /wp-content/plugins/wp-admin-ui/inc/functions/options-profil.php
    • > /wp-content/plugins/wp-admin-ui/inc/functions/options-login.php
    • > /wp-content/plugins/wp-admin-ui/inc/admin/ajax.php
    • > /wp-content/plugins/wp-admin-ui/inc/admin/pointers.php
    • > /wp-content/plugins/wp-admin-ui/inc/functions/options-editor.php
    • > /wp-content/plugins/wp-admin-ui/inc/functions/options-media-library.php
    • > /wp-content/plugins/wp-admin-ui/inc/functions/options-import-export.php

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

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
  • Tags: There are too many tags (12 tag instead of maximum 10)
  • Requires at least: The plugin version is formatted incorrectly
The official readme.txt might help

wp-admin-ui/wpadminui.php 92% from 13 tests

The entry point to "WP Admin UI" version 1.9.10 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("wp-admin-ui.php" instead of "wpadminui.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected12,118 lines of code in 54 files:
LanguageFilesBlank linesComment linesLines of code
PHP171,1143196,486
CSS175538893,252
PO File28941,0921,660
Sass111505532
JavaScript7153188

PHP code Passed 2 tests

An short overview of 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.46
Average class complexity323.00
▷ Minimum class complexity323.00
▷ Maximum class complexity323.00
Average method complexity2.97
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods153
▷ Static methods00.00%
▷ Public methods153100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions220
▷ Named functions21798.64%
▷ Anonymous functions31.36%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.08MB with 0.05MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/img/seopress.png78.85KB24.55KB▼ 68.86%
assets/img/logo-wpui.png6.37KB3.10KB▼ 51.36%