68% onlinemenukaart

Code Review | Onlinemenukaart

WordPress plugin Onlinemenukaart scored 68% from 54 tests.

About plugin

  • Plugin page: onlinemenukaart
  • Plugin version: 0.1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-6.0.0
  • WordPress version: 6.3.1
  • First release: Oct 28, 2020
  • Latest release: May 6, 2022
  • Number of updates: 4
  • Update frequency: every 139.2 days
  • Top authors: onlinemenukaart (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 892 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼1.84MB] [CPU: ▼49.61ms] Passed 4 tests

Server-side resources used by Onlinemenukaart
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.14 ▼1.324.59 ▼36.76
Dashboard /wp-admin2.16 ▼1.146.48 ▼39.61
Posts /wp-admin/edit.php2.16 ▼1.195.32 ▼40.98
Add New Post /wp-admin/post-new.php2.16 ▼3.726.32 ▼81.10
Media Library /wp-admin/upload.php2.16 ▼1.065.63 ▼25.59

Server storage [IO: ▲0.50MB] [DB: ▲0.07MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 183 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
widget_recent-comments
theysaidso_admin_options
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Onlinemenukaart
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,863 ▲12813.17 ▼1.581.74 ▲0.1241.33 ▼1.53
Dashboard /wp-admin2,260 ▲715.83 ▲0.9097.84 ▼20.2537.95 ▼2.37
Posts /wp-admin/edit.php2,146 ▲572.04 ▲0.0639.12 ▼1.9334.35 ▼1.26
Add New Post /wp-admin/post-new.php6,433 ▲4,91920.77 ▲3.19924.92 ▲248.1654.32 ▼15.52
Media Library /wp-admin/upload.php1,439 ▲514.16 ▼0.0398.24 ▼14.7244.40 ▼5.72

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • The plugin did not uninstall gracefully
    • > User notice in wp-includes/functions.php+5905
    Function wp_register_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the onlinemenukaart handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • Zombie WordPress options were found after uninstall: 6 options
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

SRP 0% 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
  • 2× PHP files output text when accessed directly:
    • > /wp-content/plugins/onlinemenukaart/views/shortcodes/menucard.blade.php
    • > /wp-content/plugins/onlinemenukaart/views/settings.blade.php
  • 21× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Interface 'Illuminate\\Contracts\\Support\\Renderable' not found in wp-content/plugins/onlinemenukaart/vendor/illuminate/contracts/View/View.php:7
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\SimpleCache\\CacheException' not found in wp-content/plugins/onlinemenukaart/vendor/psr/simple-cache/src/InvalidArgumentException.php:11
    • > PHP Fatal error
      Uncaught Error: Interface 'Illuminate\\Contracts\\Container\\Container' not found in wp-content/plugins/onlinemenukaart/vendor/illuminate/contracts/Foundation/Application.php:7
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Container\\ContainerExceptionInterface' not found in wp-content/plugins/onlinemenukaart/vendor/psr/container/src/NotFoundExceptionInterface.php:11
    • > PHP Fatal error
      Uncaught Error: Interface 'Illuminate\\Contracts\\Broadcasting\\ShouldBroadcast' not found in wp-content/plugins/onlinemenukaart/vendor/illuminate/contracts/Broadcasting/ShouldBroadcastNow.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Container\otFoundExceptionInterface' not found in wp-content/plugins/onlinemenukaart/vendor/illuminate/container/EntryNotFoundException.php:8
    • > PHP Fatal error
      Uncaught Error: Interface 'Illuminate\\Contracts\\Validation\\Rule' not found in wp-content/plugins/onlinemenukaart/vendor/illuminate/contracts/Validation/ImplicitRule.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'Illuminate\\Contracts\\Support\\Arrayable' not found in wp-content/plugins/onlinemenukaart/vendor/illuminate/contracts/Support/MessageBag.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'Illuminate\\Contracts\\Bus\\Dispatcher' not found in wp-content/plugins/onlinemenukaart/vendor/illuminate/contracts/Bus/QueueingDispatcher.php:5
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\SimpleCache\\CacheInterface' not found in wp-content/plugins/onlinemenukaart/vendor/illuminate/contracts/Cache/Repository.php:8

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need to be fixed:
  • Contributors: The plugin contributors field is missing
Please take inspiration from this readme.txt

onlinemenukaart/onlinemenukaart.php Passed 13 tests

The primary PHP file in "Onlinemenukaart" version 0.1.0 is used by WordPress to initiate all plugin functionality
48 characters long description:
Integreer Onlinemenukaart met je Wordpress site.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin6,839 lines of code in 173 files:
LanguageFilesBlank linesComment linesLines of code
PHP1441,4356,0955,509
Markdown102370599
JSON600442
JavaScript42116165
SVG11048
Blade23035
Sass33134
CSS3007

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity5.43
▷ Minimum class complexity1.00
▷ Maximum class complexity310.00
Average method complexity2.30
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces43
Interfaces102
Traits6
Classes30
▷ Abstract classes00.00%
▷ Concrete classes30100.00%
▷ Final classes00.00%
Methods912
▷ Static methods293.18%
▷ Public methods72078.95%
▷ Protected methods17819.52%
▷ Private methods141.54%
Functions35
▷ Named functions12.86%
▷ Anonymous functions3497.14%
Constants16
▷ Global constants212.50%
▷ Class constants1487.50%
▷ Public constants14100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin