68% wpcal

Code Review | WPCal.io - Easy Meeting Scheduler

WordPress plugin WPCal.io - Easy Meeting Scheduler scored68%from 54 tests.

About plugin

  • Plugin page: wpcal
  • Plugin version: 0.9.5.8
  • PHP compatiblity: 7.1+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.4.1
  • WordPress version: 6.3.1
  • First release: May 9, 2020
  • Latest release: Nov 30, 2023
  • Number of updates: 99
  • Update frequency: every 13.4 days
  • Top authors: wpcal (100%)

Code review

54 tests

User reviews

18 reviews

Install metrics

1,000+ active /24,264 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
Installer ran successfully

Server metrics [RAM: ▲2.48MB] [CPU: ▲12.59ms] Passed 4 tests

An overview of server-side resources used by WPCal.io - Easy Meeting Scheduler
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /5.90 ▲2.4449.81 ▲9.53
Dashboard /wp-admin5.81 ▲2.4666.50 ▲3.32
Posts /wp-admin/edit.php5.92 ▲2.5664.43 ▲16.33
Add New Post /wp-admin/post-new.php8.41 ▲2.52111.38 ▲21.17
Media Library /wp-admin/upload.php5.73 ▲2.5061.79 ▲30.23

Server storage [IO: ▲8.65MB] [DB: ▲0.03MB] Passed 3 tests

Filesystem and database footprint
No storage issues were detected
Filesystem: 673 new files
Database: 15 new tables, 13 new options
New tables
wp_wpcal_service_availability
wp_wpcal_background_tasks
wp_wpcal_calendars
wp_wpcal_calendar_accounts
wp_wpcal_availability_periods
wp_wpcal_calendar_events
wp_wpcal_notices
wp_wpcal_service_admins
wp_wpcal_tp_accounts
wp_wpcal_availability_dates
...
New WordPress options
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts
wpcal_db_version
wpcal_last_local_task_started_time
wpcal_features_last_checked
wpcal_install_version
...

Browser metrics Passed 4 tests

A check of browser resources used by WPCal.io - Easy Meeting Scheduler
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,832 ▲7014.40 ▼0.201.50 ▼0.1938.04 ▼6.33
Dashboard /wp-admin2,237 ▲575.92 ▲0.2397.93 ▲6.8839.09 ▲0.57
Posts /wp-admin/edit.php2,139 ▲362.17 ▲0.1739.49 ▲4.0736.22 ▲0.11
Add New Post /wp-admin/post-new.php1,717 ▲19121.87 ▼1.44697.09 ▲59.2039.69 ▼15.53
Media Library /wp-admin/upload.php1,440 ▲404.30 ▲0.13126.84 ▲32.3654.53 ▲12.87
Bookings /wp-admin/admin.php?page=wpcal_admin#/bookings1,2287.06160.0442.38
Settings /wp-admin/admin.php?page=wpcal_admin#/settings1,2297.17141.5637.41
Event Types /wp-admin/admin.php?page=wpcal_admin#/event-types1,2247.24147.1337.85

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 15 tables in the database
    • wp_wpcal_notices
    • wp_wpcal_availability_periods
    • wp_wpcal_availability_dates
    • wp_wpcal_service_admins
    • wp_wpcal_calendars
    • wp_wpcal_service_availability
    • wp_wpcal_bookings
    • wp_wpcal_calendar_accounts
    • wp_wpcal_service_availability_slots_cache
    • wp_wpcal_background_tasks
    • ...
  • This plugin did not uninstall successfully, leaving 13 options in the database
    • wpcal_version
    • db_upgraded
    • can_compress_scripts
    • wpcal_db_version
    • widget_recent-comments
    • wpcal_last_local_task_started_time
    • wpcal_last_validate_attempt
    • wpcal_install_version
    • wpcal_first_activation_redirect
    • widget_recent-posts
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

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
Please fix the following
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/wpcal/templates/admin_page.php
    • > /wp-content/plugins/wpcal/templates/requirements_not_met.php
  • 300× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'WPCal\\GoogleAPI\\Google\\Auth\\CredentialsLoader' not found in wp-content/plugins/wpcal/lib/google-api-php-client/vendor/google/auth/src/Credentials/AppIdentityCredentials.php:52
    • > PHP Fatal error
      Uncaught Error: Class 'WPCal\\GoogleAPI\\Google_Model' not found in wp-content/plugins/wpcal/lib/google-api-php-client/vendor/google/apiclient-services/src/Google/Service/Calendar/EventGadget.php:20
    • > PHP Fatal error
      Uncaught Error: Interface 'WPCal\\GoogleAPI\\GuzzleHttp\\Handler\\CurlFactoryInterface' not found in wp-content/plugins/wpcal/lib/google-api-php-client/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php:15
    • > PHP Fatal error
      Uncaught Error: Interface 'WPCal\\ComposerPackages\\Psr\\Http\\Message\\UriInterface' not found in wp-content/plugins/wpcal/lib/composer_packages/vendor/guzzlehttp/psr7/src/Uri.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'WPCal\\GoogleAPI\\Monolog\\Handler\\StreamHandler' not found in wp-content/plugins/wpcal/lib/google-api-php-client/vendor/monolog/monolog/src/Monolog/Handler/RotatingFileHandler.php:25
    • > PHP Fatal error
      Uncaught Error: Class 'WPCal\\GoogleAPI\\GuzzleHttp\\Exception\\TransferException' not found in wp-content/plugins/wpcal/lib/google-api-php-client/vendor/guzzlehttp/guzzle/src/Exception/RequestException.php:12
    • > PHP Fatal error
      Uncaught Error: Interface 'WPCal\\GoogleAPI\\Google\\Auth\\FetchAuthTokenInterface' not found in wp-content/plugins/wpcal/lib/google-api-php-client/vendor/google/auth/src/FetchAuthTokenCache.php:25
    • > PHP Fatal error
      Uncaught Error: Class 'WPCal\\GoogleAPI\\Monolog\\Handler\\AbstractHandler' not found in wp-content/plugins/wpcal/lib/google-api-php-client/vendor/monolog/monolog/src/Monolog/Handler/BufferHandler.php:24
    • > PHP Fatal error
      Uncaught Error: Class 'WPCal\\GoogleAPI\\Google_Model' not found in wp-content/plugins/wpcal/lib/google-api-php-client/vendor/google/apiclient-services/src/Google/Service/Calendar/ConferenceParameters.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'WPCal\\GoogleAPI\\Google_Model' not found in wp-content/plugins/wpcal/lib/google-api-php-client/vendor/google/apiclient-services/src/Google/Service/Calendar/TimePeriod.php:20

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 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
Attributes that require attention:
  • Tags: You are using too many tags: 17 tag instead of maximum 10
Please take inspiration from this readme.txt

wpcal/wpcal.php Passed 13 tests

Analyzing the main PHP file in "WPCal.io - Easy Meeting Scheduler" version 0.9.5.8
77 characters long description:
Allow your customer to book appoinments online without back-and-forth emails.

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected85,737 lines of code in 614 files:
LanguageFilesBlank linesComment linesLines of code
PHP5325,21236,92663,235
JavaScript92,7188,54212,933
Markdown331,90406,025
JSON21102,529
SVG651941
YAML12025
XML10019
Dockerfile18010
make1409
CSS5005
Bourne Shell1203
HTML3003

PHP code 50% from 2 tests

Analyzing cyclomatic complexity and code structure
These items need your attention
  • Please reduce cyclomatic complexity of methods to less than 100 (currently 109)
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity19.82
▷ Minimum class complexity1.00
▷ Maximum class complexity628.00
Average method complexity3.17
▷ Minimum method complexity1.00
▷ Maximum method complexity109.00
Code structure
Namespaces54
Interfaces49
Traits18
Classes417
▷ Abstract classes153.60%
▷ Concrete classes40296.40%
▷ Final classes256.22%
Methods4,355
▷ Static methods54412.49%
▷ Public methods3,47179.70%
▷ Protected methods3257.46%
▷ Private methods55912.84%
Functions576
▷ Named functions35461.46%
▷ Anonymous functions22238.54%
Constants473
▷ Global constants9019.03%
▷ Class constants38380.97%
▷ Public constants36495.04%

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 are no PNG files in this plugin