10% descriptive-menu-widget

Code Review | Descriptive Menu Plugin

WordPress plugin Descriptive Menu Plugin scored10%from 54 tests.

About plugin

  • Plugin page: descriptive-menu-...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-3.6.1
  • WordPress version: 6.3.1
  • First release: Sep 13, 2013
  • Latest release: Nov 25, 2013
  • Number of updates: 6
  • Update frequency: every 12.2 days
  • Top authors: AcumenConsulting (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

60+ active /3,560 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The following installer errors require your attention
  • This plugin did not install gracefully
    • > Warning in wp-content/plugins/descriptive-menu-widget/descriptive-menu.php+26
    Declaration of Menu_With_Description::start_el(&$output, $item, $depth, $args) should be compatible with Walker_Nav_Menu::start_el(&$output, $data_object, $depth = 0, $args = NULL, $current_object_id = 0)

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

Server-side resources used by Descriptive Menu Plugin
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.444.48 ▼40.30
Dashboard /wp-admin2.05 ▼1.265.35 ▼49.82
Posts /wp-admin/edit.php2.05 ▼1.315.82 ▼45.61
Add New Post /wp-admin/post-new.php2.05 ▼3.845.57 ▼88.43
Media Library /wp-admin/upload.php2.05 ▼1.185.71 ▼31.19

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 2 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
widget_descriptive_menu
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for Descriptive Menu Plugin
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.35 ▲0.001.70 ▼0.1843.02 ▼1.02
Dashboard /wp-admin2,195 ▲155.57 ▼0.0986.52 ▼5.0638.68 ▼1.88
Posts /wp-admin/edit.php2,103 ▲241.97 ▼0.0233.72 ▼2.7435.34 ▼0.98
Add New Post /wp-admin/post-new.php1,526 ▼023.11 ▼0.46644.19 ▼53.5057.40 ▲1.38
Media Library /wp-admin/upload.php1,400 ▼04.09 ▼0.13110.20 ▲1.0546.58 ▼1.53

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • Uninstall procedure validation failed for this plugin
    • > Warning in wp-content/plugins/descriptive-menu-widget/descriptive-menu.php+26
    Declaration of Menu_With_Description::start_el(&$output, $item, $depth, $args) should be compatible with Walker_Nav_Menu::start_el(&$output, $data_object, $depth = 0, $args = NULL, $current_object_id = 0)
  • Zombie WordPress options were found after uninstall: 7 options
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • widget_descriptive_menu
    • theysaidso_admin_options
    • widget_theysaidso_widget

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

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
Please fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'Walker_Nav_Menu' not found in wp-content/plugins/descriptive-menu-widget/descriptive-menu.php:13

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
7 plugin tags: css, widget, links, plugin, menu...

descriptive-menu-widget/descriptive-menu.php 92% from 13 tests

The main file in "Descriptive Menu Plugin" v. 1.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("descriptive-menu-widget.php" instead of "descriptive-menu.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected109 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP12617109

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity16.00
▷ Minimum class complexity13.00
▷ Maximum class complexity19.00
Average method complexity6.00
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods6
▷ Static methods00.00%
▷ Public methods6100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
No PNG files were detected