84% yogo-booking

Code Review | YOGO Booking

WordPress plugin YOGO Booking scored84%from 54 tests.

About plugin

  • Plugin page: yogo-booking
  • Plugin version: 1.4.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.1
  • WordPress version: 6.3.1
  • First release: Dec 10, 2022
  • Latest release: Dec 14, 2022
  • Number of updates: 9
  • Update frequency: every 0.6 days
  • Top authors: andersyogo (100%)

Code review

54 tests

User reviews

1 review

Install metrics

50+ active /568 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.05MB] [CPU: ▼9.90ms] Passed 4 tests

This is a short check of server-side resources used by YOGO Booking
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0537.96 ▼7.06
Dashboard /wp-admin3.36 ▲0.0548.88 ▲0.88
Posts /wp-admin/edit.php3.41 ▲0.0548.90 ▼2.50
Add New Post /wp-admin/post-new.php5.94 ▲0.0596.38 ▼24.81
Media Library /wp-admin/upload.php3.28 ▲0.0535.54 ▼5.22

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for YOGO Booking
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,842 ▲7113.24 ▼0.795.77 ▲3.6948.28 ▼1.86
Dashboard /wp-admin2,217 ▲295.79 ▼0.08116.14 ▲5.40102.46 ▲59.84
Posts /wp-admin/edit.php2,103 ▲142.06 ▲0.0143.76 ▼19.6641.45 ▲1.49
Add New Post /wp-admin/post-new.php1,536 ▲1723.20 ▲0.17708.21 ▲68.8076.91 ▼8.70
Media Library /wp-admin/upload.php1,399 ▲114.20 ▼0.00111.15 ▼44.3858.66 ▲4.94

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting 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 take a closer look at the following
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/yogo-booking/src/admin.php:29
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/yogo-booking/src/shortcodes.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/yogo-booking/src/shortcodes.php:3

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)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
5 plugin tags: training, fitness, yoga, schedule, booking

yogo-booking/yogo.php 92% from 13 tests

The entry point to "YOGO Booking" version 1.4.0 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("yogo-booking.php" instead of "yogo.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin308 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP36633197
PO File2222296
Markdown16014
JavaScript1001

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.47
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%
Functions18
▷ Named functions844.44%
▷ Anonymous functions1055.56%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
src/images/logo.png0.53KB0.37KB▼ 30.39%