Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully
Server metrics [RAM: ▲0.85MB] [CPU: ▼2.84ms] Passed 4 tests
Analyzing server-side resources used by Restaurant Reservations
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.32 ▲0.86 | 41.77 ▲1.83 |
Dashboard /wp-admin | 4.18 ▲0.83 | 49.68 ▼13.01 |
Posts /wp-admin/edit.php | 4.29 ▲0.93 | 52.57 ▲5.74 |
Add New Post /wp-admin/post-new.php | 6.76 ▲0.87 | 90.84 ▼5.45 |
Media Library /wp-admin/upload.php | 4.10 ▲0.87 | 41.63 ▲5.27 |
Add New /wp-admin/post-new.php?post_type=nd_rst_cpt_1 | 4.22 | 54.24 |
Add Timing /wp-admin/admin.php?page=nd-restaurant-reservations-add-timing | 4.06 | 37.74 |
Calendar View /wp-admin/admin.php?page=nd-restaurant-reservations-settings-calendar-view | 4.04 | 36.68 |
Add Exceptions /wp-admin/admin.php?page=nd-restaurant-reservations-add-exception | 4.06 | 36.76 |
Paypal /wp-admin/admin.php?page=nd-restaurant-reservations-paypal | 4.07 | 39.79 |
All Orders /wp-admin/admin.php?page=nd-restaurant-reservations-settings-orders | 4.12 | 35.65 |
ND Restaurant /wp-admin/admin.php?page=nd-restaurant-reservations-settings | 4.07 | 38.90 |
Reservation Settings /wp-admin/admin.php?page=nd-restaurant-reservations-reservation-settings | 4.07 | 37.00 |
Restaurants /wp-admin/edit.php?post_type=nd_rst_cpt_1 | 4.14 | 39.40 |
Import Export /wp-admin/admin.php?page=nd-restaurant-reservations-settings-import-export | 4.06 | 34.99 |
Server storage [IO: ▲0.75MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
This plugin was installed successfully
Filesystem: 87 new files
Database: 1 new table, 6 new options
New tables |
---|
wp_nd_rst_booking |
New WordPress options |
---|
theysaidso_admin_options |
widget_recent-comments |
db_upgraded |
can_compress_scripts |
widget_recent-posts |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
Checking browser requirements for Restaurant Reservations
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,983 ▲222 | 13.42 ▼0.98 | 7.75 ▲6.17 | 38.61 ▲2.04 |
Dashboard /wp-admin | 2,302 ▲131 | 5.57 ▼0.01 | 83.84 ▼6.97 | 38.89 ▼3.89 |
Posts /wp-admin/edit.php | 2,207 ▲107 | 2.02 ▼0.01 | 40.33 ▲0.84 | 38.54 ▲4.62 |
Add New Post /wp-admin/post-new.php | 1,614 ▲87 | 22.89 ▼0.07 | 652.30 ▼34.45 | 66.79 ▲10.55 |
Media Library /wp-admin/upload.php | 1,507 ▲110 | 4.29 ▲0.09 | 98.14 ▼1.69 | 41.86 ▼4.81 |
Add New /wp-admin/post-new.php?post_type=nd_rst_cpt_1 | 2,310 | 7.63 | 160.97 | 66.57 |
Add Timing /wp-admin/admin.php?page=nd-restaurant-reservations-add-timing | 980 | 1.78 | 25.28 | 27.36 |
Calendar View /wp-admin/admin.php?page=nd-restaurant-reservations-settings-calendar-view | 996 | 1.96 | 28.91 | 26.32 |
Add Exceptions /wp-admin/admin.php?page=nd-restaurant-reservations-add-exception | 996 | 2.16 | 22.47 | 23.57 |
Paypal /wp-admin/admin.php?page=nd-restaurant-reservations-paypal | 1,318 | 2.01 | 23.04 | 27.91 |
All Orders /wp-admin/admin.php?page=nd-restaurant-reservations-settings-orders | 877 | 2.05 | 24.17 | 24.32 |
ND Restaurant /wp-admin/admin.php?page=nd-restaurant-reservations-settings | 1,359 | 2.17 | 22.90 | 26.23 |
Reservation Settings /wp-admin/admin.php?page=nd-restaurant-reservations-reservation-settings | 1,181 | 2.01 | 23.43 | 27.18 |
Restaurants /wp-admin/edit.php?post_type=nd_rst_cpt_1 | 1,180 | 1.94 | 31.02 | 31.50 |
Import Export /wp-admin/admin.php?page=nd-restaurant-reservations-settings-import-export | 1,033 | 2.16 | 23.69 | 26.34 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
- The uninstall procedure failed, leaving 1 table in the database
- wp_nd_rst_booking
- This plugin did not uninstall successfully, leaving 6 options in the database
- can_compress_scripts
- widget_recent-comments
- widget_recent-posts
- widget_theysaidso_widget
- db_upgraded
- theysaidso_admin_options
Smoke tests 50% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
These server-side errors were triggered
- > GET request to /wp-admin/admin.php?page=nd-restaurant-reservations-settings-calendar-view
- > Notice in wp-content/plugins/nd-restaurant-reservations/addons/calendar-view/index.php+20
Undefined index: nd_rst_arrive_from_filter
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=nd-restaurant-reservations-settings-orders
- > Notice in wp-content/plugins/nd-restaurant-reservations/inc/admin/3-orders/include/orders.php+7
Undefined index: nd_rst_order_status
- > GET request to /wp-admin/admin.php?page=nd-restaurant-reservations-settings-calendar-view
- > Notice in wp-content/plugins/nd-restaurant-reservations/addons/calendar-view/index.php+22
Undefined index: nd_rst_date
- > GET request to /wp-admin/admin.php?page=nd-restaurant-reservations-settings-calendar-view
- > Notice in wp-content/plugins/nd-restaurant-reservations/addons/calendar-view/index.php+23
Undefined index: nd_rst_restaurant
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=nd-restaurant-reservations-settings-calendar-view
- > Notice in wp-content/plugins/nd-restaurant-reservations/inc/functions/functions.php+55
A non well formed numeric value encountered
- > GET request to /wp-admin/admin.php?page=nd-restaurant-reservations-settings-orders
- > Notice in wp-content/plugins/nd-restaurant-reservations/inc/admin/3-orders/include/orders.php+5
Undefined index: nd_rst_pag_from
- > GET request to /wp-admin/admin.php?page=nd-restaurant-reservations-settings-orders
- > Notice in wp-content/plugins/nd-restaurant-reservations/inc/admin/3-orders/include/orders.php+6
Undefined index: nd_rst_pag_to
- > GET request to /wp-admin/admin.php?page=nd-restaurant-reservations-settings-orders
- > User notice in wp-includes/functions.php+5905
Function wpdb::prepare was called incorrectly. The query argument of wpdb::prepare() must have a placeholder. Please see Debugging in WordPress for more information. (This message was added in version 3.9.0.)
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
- 40× PHP files trigger server errors when accessed directly (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function get_option() in wp-content/plugins/nd-restaurant-reservations/inc/admin/8-premium-addons/index.php:4
- > PHP Fatal error
Uncaught Error: Call to undefined function sanitize_text_field() in wp-content/plugins/nd-restaurant-reservations/inc/admin/3-orders/include/edit.php:4
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nd-restaurant-reservations/inc/admin/3-orders/include/add.php:4
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nd-restaurant-reservations/inc/admin/plugin-settings.php:5
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/nd-restaurant-reservations/addons/calendar-view/index.php:6
- > PHP Fatal error
Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/nd-restaurant-reservations/addons/visual/search/index.php:5
- > PHP Notice
Undefined variable: nd_rst_date in wp-content/plugins/nd-restaurant-reservations/inc/shortcodes/include/nd_rst_reservation_details.php on line 4
- > PHP Fatal error
Uncaught Error: Call to undefined function get_option() in wp-content/plugins/nd-restaurant-reservations/addons/visual/search/layout/layout-2.php:4
- > PHP Notice
Undefined variable: nd_rst_date in wp-content/plugins/nd-restaurant-reservations/inc/shortcodes/include/nd_rst_reservation_confirm.php on line 5
- > PHP Warning
cal_days_in_month(): invalid date in wp-content/plugins/nd-restaurant-reservations/inc/shortcodes/include/nd_rst_reservation_calendar.php on line 6
- > PHP Fatal error
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)
There were no browser issues found
Optimizations
Plugin configuration 96% from 29 tests
readme.txt Passed 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
2 plugin tags: table, restaurants
nd-restaurant-reservations/nd-restaurant-reservations.php 92% from 13 tests
The main PHP file in "Restaurant Reservations" ver. 1.9 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
- Description: Keep the plugin description shorter than 140 characters (currently 219 characters long)
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected7,383 lines of code in 51 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 35 | 3,012 | 406 | 5,740 |
CSS | 10 | 179 | 74 | 1,024 |
JavaScript | 4 | 351 | 156 | 543 |
SVG | 2 | 0 | 2 | 76 |
PHP code Passed 2 tests
A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.18 |
Average class complexity | 4.00 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 8.00 |
Average method complexity | 1.45 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 4.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 3 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 3 | 100.00% |
▷ Final classes | 1 | 33.33% |
Methods | 20 | |
▷ Static methods | 1 | 5.00% |
▷ Public methods | 16 | 80.00% |
▷ Protected methods | 4 | 20.00% |
▷ Private methods | 0 | 0.00% |
Functions | 70 | |
▷ Named functions | 70 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 3 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 3 | 100.00% |
▷ Public constants | 3 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
All PNG images should be compressed to minimize bandwidth usage for end users
24 PNG files occupy 0.21MB with 0.19MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
inc/shortcodes/include/002-calendar.png | 15.74KB | 0.76KB | ▼ 95.15% |
assets/img/icon-down-greydark.png | 1.06KB | 0.19KB | ▼ 82.38% |
assets/img/remove.png | 14.69KB | 0.15KB | ▼ 98.97% |
assets/img/004-restaurant.png | 18.86KB | 3.49KB | ▼ 81.48% |
assets/img/002-calendar.png | 15.74KB | 0.76KB | ▼ 95.15% |