84% restaurant-addon-for-elementor

Code Review | Restaurant Addon for Elementor

WordPress plugin Restaurant Addon for Elementor scored84%from 54 tests.

About plugin

  • Plugin page: restaurant-addon-...
  • Plugin version: 1.1
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-4.9
  • WordPress version: 6.3.1
  • First release: Nov 17, 2018
  • Latest release: Nov 23, 2018
  • Number of updates: 3
  • Update frequency: every 2.0 days
  • Top authors: hinterfold (100%)

Code review

54 tests

User reviews

1 review

Install metrics

300+ active /3,048 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.01MB] [CPU: ▼7.54ms] Passed 4 tests

Server-side resources used by Restaurant Addon for Elementor
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0036.31 ▲0.96
Dashboard /wp-admin3.31 ▼0.0444.88 ▼15.59
Posts /wp-admin/edit.php3.36 ▲0.0045.48 ▼1.23
Add New Post /wp-admin/post-new.php5.89 ▲0.0078.39 ▼14.29
Media Library /wp-admin/upload.php3.23 ▲0.0034.05 ▲2.58

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

Restaurant Addon for Elementor: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲6014.35 ▼0.271.65 ▲0.1142.22 ▲4.41
Dashboard /wp-admin2,206 ▲295.55 ▼0.0085.04 ▼1.3538.12 ▼4.95
Posts /wp-admin/edit.php2,117 ▲172.04 ▲0.1042.06 ▲6.8743.53 ▲5.54
Add New Post /wp-admin/post-new.php1,538 ▲1223.52 ▼0.16668.25 ▼22.8163.73 ▲13.01
Media Library /wp-admin/upload.php1,420 ▲204.17 ▼0.0298.58 ▲2.3242.51 ▼0.67

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

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 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function RestaurantAddonForElementor\\add_action() in wp-content/plugins/restaurant-addon-for-elementor/plugin.php:113

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed:
  • Screenshots: Please a description for screenshot #4 in restaurant-addon-for-elementor/assets to your readme.txt
  • Tags: Too many tags (17 tag instead of maximum 10); only the first 5 tags are used in your directory listing
Please take inspiration from this readme.txt

restaurant-addon-for-elementor/restaurant-addon-for-elementor.php Passed 13 tests

The main PHP script in "Restaurant Addon for Elementor" version 1.1 is automatically included on every request by WordPress
78 characters long description:
Adds easy to configure Elementor widgets specific for the restaurant industry.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected360 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP586317338
CSS14022

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity4.50
▷ Minimum class complexity2.00
▷ Maximum class complexity7.00
Average method complexity1.54
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces2
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes125.00%
Methods26
▷ Static methods13.85%
▷ Public methods1973.08%
▷ Protected methods623.08%
▷ Private methods13.85%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants00.00%
▷ Class constants3100.00%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin