84% generate-legacy-mobile-menu

Code Review | Generate Legacy Mobile Menu

WordPress plugin Generate Legacy Mobile Menu scored84%from 54 tests.

About plugin

  • Plugin page: generate-legacy-m...
  • Plugin version: 0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.3
  • WordPress version: 6.3.1
  • First release: Apr 24, 2015
  • Latest release: Aug 20, 2015
  • Number of updates: 5
  • Update frequency: every 23.6 days
  • Top authors: edge22 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,802 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.00MB] [CPU: ▼11.09ms] Passed 4 tests

An overview of server-side resources used by Generate Legacy Mobile Menu
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0043.28 ▼3.60
Dashboard /wp-admin3.31 ▲0.0048.40 ▼21.12
Posts /wp-admin/edit.php3.36 ▲0.0046.99 ▼2.01
Add New Post /wp-admin/post-new.php5.89 ▲0.0085.12 ▼17.64
Media Library /wp-admin/upload.php3.23 ▲0.0036.82 ▼1.39

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Generate Legacy Mobile Menu
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.23 ▼0.331.78 ▲0.1046.50 ▲4.00
Dashboard /wp-admin2,195 ▲215.51 ▼0.1485.39 ▼8.0538.35 ▼1.36
Posts /wp-admin/edit.php2,100 ▲31.96 ▼0.0435.08 ▲0.1136.19 ▲0.75
Add New Post /wp-admin/post-new.php1,526 ▼023.68 ▲0.46671.91 ▼15.1767.02 ▲15.69
Media Library /wp-admin/upload.php1,403 ▲34.21 ▲0.00100.24 ▼12.9948.21 ▼0.47

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% 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
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means 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 fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/generate-legacy-mobile-menu/generate-legacy-mobile-menu.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
2 plugin tags: legacy mobile menu, generatepress

generate-legacy-mobile-menu/generate-legacy-mobile-menu.php Passed 13 tests

Analyzing the main PHP file in "Generate Legacy Mobile Menu" version 0.2
137 characters long description:
Revert back to the legacy version of the mobile navigation in the GeneratePress theme. GeneratePress is required for this plugin to work.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected149 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript23030123
PHP151022
CSS1004

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
PNG images were not found in this plugin