78% wp-mmenu-lite

Code Review | WP MMenu Lite

WordPress plugin WP MMenu Lite scored78%from 54 tests.

About plugin

  • Plugin page: wp-mmenu-lite
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.9.1
  • WordPress version: 6.3.1
  • First release: Jul 24, 2014
  • Latest release: Jul 24, 2014
  • Number of updates: 7
  • Update frequency: every 25.3 days
  • Top authors: jamesdbruner (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /5,175 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.10MB] [CPU: ▲0.46ms] Passed 4 tests

Server-side resources used by WP MMenu Lite
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.66 ▲0.2041.51 ▼2.74
Dashboard /wp-admin3.47 ▲0.1644.97 ▲1.04
Posts /wp-admin/edit.php3.52 ▲0.1648.05 ▲5.72
Add New Post /wp-admin/post-new.php5.88 ▼0.0093.80 ▲3.92
Media Library /wp-admin/upload.php3.33 ▲0.1034.66 ▼0.38
Mobile Menu Lite /wp-admin/options-general.php?page=mmenu_options_lite3.4234.99

Server storage [IO: ▲3.11MB] [DB: ▲0.00MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
It is recommended to fix the following issues
  • There were 1 file (0.00KB) illegally modified outside of "wp-content/plugins/wp-mmenu-lite/" and "wp-content/uploads/"
    • (new file) wp-content/redux/.empty
Filesystem: 259 new files
Database: no new tables, 9 new options
New WordPress options
widget_recent-posts
mmenulite
redux-framework-tracking
mmenulite-transients
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 WP MMenu Lite
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,899 ▲15313.69 ▼0.699.06 ▲7.3640.88 ▼4.19
Dashboard /wp-admin2,210 ▲224.85 ▼0.9699.31 ▼4.1437.85 ▼6.96
Posts /wp-admin/edit.php2,093 ▲42.05 ▼0.0039.80 ▲5.2236.43 ▼0.19
Add New Post /wp-admin/post-new.php1,536 ▲322.96 ▼0.14589.25 ▼84.1853.66 ▼2.49
Media Library /wp-admin/upload.php1,392 ▲14.20 ▼0.0298.45 ▼9.8542.64 ▼1.27
Mobile Menu Lite /wp-admin/options-general.php?page=mmenu_options_lite1,4054.0470.9138.75

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
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 9 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • mmenulite-transients
    • can_compress_scripts
    • redux-framework-tracking
    • db_upgraded
    • mmenulite
    • widget_recent-comments
    • theysaidso_admin_options

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

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Almost there! Just fix the following items
  • 3× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/wp-mmenu-lite/admin/redux-framework/bin/makepot/pot-ext-meta.php
    • > /wp-content/plugins/wp-mmenu-lite/admin/redux-framework/bin/makepot/index.php
    • > /wp-content/plugins/wp-mmenu-lite/admin/redux-framework/bin/makepot/not-gettexted.php
  • 6× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_UnitTestCase' not found in wp-content/plugins/wp-mmenu-lite/admin/redux-framework/tests/test-sample.php:3
    • > PHP Fatal error
      require(): Failed opening required 'wp-content/bootstrap.php' (include_path='.:/usr/share/php') in wp-content/plugins/wp-mmenu-lite/admin/redux-framework/bootstrap_tests.php on line 27
    • > PHP Warning
      require_once(/functions.php): failed to open stream: No such file or directory in wp-content/plugins/wp-mmenu-lite/admin/redux-framework/tests/bootstrap.php on line 14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/wp-mmenu-lite/admin/redux-framework/ReduxCore/inc/fields/select/elusive-icons.php:312
    • > PHP Warning
      require(wp-content/bootstrap.php): failed to open stream: No such file or directory in wp-content/plugins/wp-mmenu-lite/admin/redux-framework/bootstrap_tests.php on line 27
    • > PHP Fatal error
      require_once(): Failed opening required '/functions.php' (include_path='.:/usr/share/php') in wp-content/plugins/wp-mmenu-lite/admin/redux-framework/tests/bootstrap.php on line 14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
5 plugin tags: mmenu, app menu, mobile menu, menu, jquery menu

wp-mmenu-lite/mmenu-lite.php 92% from 13 tests

The main file in "WP MMenu Lite" v. 1.0.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("wp-mmenu-lite.php" instead of "mmenu-lite.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 detected25,529 lines of code in 176 files:
LanguageFilesBlank linesComment linesLines of code
PHP622,1333,6519,104
JavaScript711,7361,5828,487
CSS163851453,441
LESS82811772,807
Markdown42720888
SVG100309
Bourne Shell56848159
XML210104
JSON30098
Sass31072
HTML18060

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.53
Average class complexity29.98
▷ Minimum class complexity1.00
▷ Maximum class complexity754.00
Average method complexity5.06
▷ Minimum method complexity1.00
▷ Maximum method complexity90.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes56
▷ Abstract classes00.00%
▷ Concrete classes56100.00%
▷ Final classes00.00%
Methods400
▷ Static methods6416.00%
▷ Public methods38295.50%
▷ Protected methods00.00%
▷ Private methods184.50%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants13
▷ Global constants430.77%
▷ Class constants969.23%
▷ Public constants9100.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
36 PNG files occupy 0.19MB with 0.04MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/redux-framework/sample/patterns/tree_bark.png41.37KB43.65KB0.00%
admin/redux-framework/ReduxCore/assets/img/2cr.png2.92KB0.24KB▼ 91.69%
admin/redux-framework/ReduxCore/assets/css/vendor/jquery-ui-bootstrap/images/ui-bg_glass_75_ffffff_1x400.png0.10KB0.10KB▼ 4.67%
admin/redux-framework/ReduxCore/assets/img/1c.png0.13KB0.13KB▼ 0.72%
admin/redux-framework/sample/patterns/triangular_@2X.png0.21KB0.25KB0.00%