10% optimized-dropdown-menus

Code Review | Optimized Dropdown Menus

WordPress plugin Optimized Dropdown Menus scored10%from 54 tests.

About plugin

  • Plugin page: optimized-dropdow...
  • Plugin version: 1.2.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.8.3
  • WordPress version: 6.3.1
  • First release: Mar 11, 2012
  • Latest release: Apr 21, 2014
  • Number of updates: 30
  • Update frequency: every 25.7 days
  • Top authors: maor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /7,853 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
These installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/optimized-dropdown-menus/optimized-dm.php+30
    Methods with the same name as their class will not be constructors in a future version of PHP; Optimized_Dropdown_Widget has a deprecated constructor

Server metrics [RAM: ▼1.91MB] [CPU: ▼47.27ms] Passed 4 tests

Analyzing server-side resources used by Optimized Dropdown Menus
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.08 ▼1.384.84 ▼31.38
Dashboard /wp-admin2.10 ▼1.206.95 ▼40.33
Posts /wp-admin/edit.php2.10 ▼1.266.44 ▼38.15
Add New Post /wp-admin/post-new.php2.10 ▼3.796.47 ▼77.73
Media Library /wp-admin/upload.php2.10 ▼1.135.36 ▼32.86

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 10 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
widget_optimzed_dd_widget
db_upgraded
widget_recent-posts
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Optimized Dropdown Menus
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲3914.63 ▲0.281.96 ▲0.2845.55 ▲1.78
Dashboard /wp-admin2,195 ▲185.57 ▼0.0687.48 ▼6.3942.03 ▼5.38
Posts /wp-admin/edit.php2,100 ▼02.03 ▲0.0636.79 ▲0.5133.71 ▼5.13
Add New Post /wp-admin/post-new.php1,535 ▲718.37 ▼4.62647.56 ▼20.8760.79 ▼15.35
Media Library /wp-admin/upload.php1,397 ▲34.13 ▼0.0397.59 ▲2.6743.63 ▲2.49

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • Uninstall procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/optimized-dropdown-menus/optimized-dm.php+30
    Methods with the same name as their class will not be constructors in a future version of PHP; Optimized_Dropdown_Widget has a deprecated constructor
  • Zombie WordPress options were found after uninstall: 7 options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • widget_optimzed_dd_widget
    • widget_theysaidso_widget
    • theysaidso_admin_options

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

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please take a closer look at the following
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/optimized-dropdown-menus/optimized-dm.php:30

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)
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need your attention:
  • Screenshots: Please add images for these screenshots: #1 (Widget Settings), #2 (How it looks on the front-end)
The official readme.txt is a good inspiration

optimized-dropdown-menus/optimized-dm.php 85% from 13 tests

"Optimized Dropdown Menus" version 1.2.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
It is important to fix the following:
  • Text Domain: The text domain should only use lowercase characters and dashes
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("optimized-dropdown-menus.php" instead of "optimized-dm.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected179 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP22839127
PO File2121652

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity9.00
▷ Minimum class complexity2.00
▷ Maximum class complexity16.00
Average method complexity2.78
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods9
▷ Static methods00.00%
▷ Public methods9100.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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There were not PNG files found in your plugin