93% add-to-menus-lite

Code Review | Add To Menus Lite

WordPress plugin Add To Menus Lite scored 93% from 54 tests.

About plugin

  • Plugin page: add-to-menus-lite
  • Plugin version: 0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.5
  • WordPress version: 5.9.2
  • First release: Apr 18, 2016
  • Latest release: May 21, 2016
  • Number of updates: 20
  • Update frequency: every 2.3 days
  • Top authors: ravisakya (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active / 1,695 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.12MB] [CPU: ▼306.26ms] Passed 4 tests

A check of server-side resources used by Add To Menus Lite
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.69 ▲0.1851.45 ▲2.79
Dashboard /wp-admin3.56 ▲0.1535.60 ▼2.55
Posts /wp-admin/edit.php3.78 ▲0.1438.93 ▲0.48
Add New Post /wp-admin/post-new.php7.02 ▲0.0596.38 ▼1,220.98
Media Library /wp-admin/upload.php3.43 ▲0.1426.26 ▼2.00

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

An overview of browser requirements for Add To Menus Lite
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,771 ▲1715.82 ▲0.155.65 ▼0.552.22 ▼0.59
Dashboard /wp-admin2,901 ▲476.15 ▼0.00115.54 ▼19.22153.37 ▼6.08
Posts /wp-admin/edit.php2,702 ▲113.24 ▼0.1362.73 ▼1.10140.50 ▼2.44
Add New Post /wp-admin/post-new.php1,693 ▲3219.20 ▲3.06388.26 ▼11.19177.95 ▲19.00
Media Library /wp-admin/upload.php1,706 ▲85.59 ▲0.05142.03 ▼7.09186.43 ▲0.62

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% 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
Please take a closer look at the following
  • 3× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/add-to-menus-lite/index.php:18
    • > PHP Fatal error
      Uncaught Error: Class 'Walker_Nav_Menu' not found in wp-content/plugins/add-to-menus-lite/custom_walker.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Walker_Nav_Menu' not found in wp-content/plugins/add-to-menus-lite/class.Walker_Nav_Menu_Edit.php:15

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


Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Tags: There are too many tags (15 tag instead of maximum 10)
  • Screenshots: Add descriptions for screenshots #2, #3, #4, #5 in add-to-menus-lite/assets to your readme.txt
You can look at the official readme.txt

add-to-menus-lite/index.php 85% from 13 tests

"Add To Menus Lite" version 0.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("add-to-menus-lite.php" instead of "index.php")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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
Good job! No executable or dangerous file extensions detected1,103 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity33.67
▷ Minimum class complexity5.00
▷ Maximum class complexity76.00
Average method complexity4.16
▷ Minimum method complexity1.00
▷ Maximum method complexity20.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
▷ Static methods00.00%
▷ Public methods31100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
▷ Named functions00.00%
▷ Anonymous functions00.00%
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG images were found in this plugin