68% resaline

Code Review | Calendrier de Réservation Resaline - Booking Calendar

WordPress plugin Calendrier de Réservation Resaline - Booking Calendar scored68%from 54 tests.

About plugin

  • Plugin page: resaline
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-3.5.1
  • WordPress version: 6.3.1
  • First release: Jul 8, 2013
  • Latest release: Aug 23, 2013
  • Number of updates: 47
  • Update frequency: every 1.0 days
  • Top authors: jeremy.pele (100%)

Code review

54 tests

User reviews

1 review

Install metrics

70+ active /6,987 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
Install script ran successfully

Server metrics [RAM: ▼1.92MB] [CPU: ▼53.63ms] Passed 4 tests

An overview of server-side resources used by Calendrier de Réservation Resaline - Booking Calendar
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.08 ▼1.395.78 ▼32.63
Dashboard /wp-admin2.10 ▼1.258.05 ▼53.63
Posts /wp-admin/edit.php2.10 ▼1.266.31 ▼37.12
Add New Post /wp-admin/post-new.php2.10 ▼3.796.80 ▼91.12
Media Library /wp-admin/upload.php2.10 ▼1.135.70 ▼31.14
Resaline Configuration /wp-admin/plugins.php?page=resaline-config2.206.73

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Calendrier de Réservation Resaline - Booking Calendar
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,826 ▲6514.34 ▼0.031.81 ▲0.1246.99 ▲6.58
Dashboard /wp-admin2,206 ▲265.55 ▼0.1291.07 ▼3.1944.64 ▲6.70
Posts /wp-admin/edit.php2,111 ▲111.98 ▼0.0143.93 ▲9.4537.80 ▼3.59
Add New Post /wp-admin/post-new.php1,533 ▲423.21 ▼0.04681.36 ▲62.3191.63 ▲34.95
Media Library /wp-admin/upload.php1,402 ▲24.22 ▲0.0594.67 ▼4.5542.40 ▼4.66
Resaline Configuration /wp-admin/plugins.php?page=resaline-config8492.0325.5728.80

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Uninstall procedure validation failed for this plugin
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_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 resaline_style 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
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
These server-side errors were triggered
    • > GET request to /wp-admin/plugins.php?page=resaline-config
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_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 resaline_style handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
    • > GET request to /wp-admin/plugins.php?page=resaline-config
    • > Notice in wp-content/plugins/resaline/admin.php+138
    Undefined variable: ms

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
The following issues need your attention
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/resaline/admin.php:2
    • > PHP Fatal error
      Uncaught Error: Class '_WP_Editors' not found in wp-content/plugins/resaline/assets/js/admin/editor_plugin_lang.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)
There were no browser issues found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 81% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: Please add images for these screenshots: #1 (Calendar on demo site), #2 (Add calendar button on resaline plugin wordpress.)
  • Tags: Please delete some tags, you are using 29 tag instead of maximum 10
  • Donate link: Invalid url: "www.resaline.net"
You can take inspiration from this readme.txt

resaline/resaline.php Passed 13 tests

Analyzing the main PHP file in "Calendrier de Réservation Resaline - Booking Calendar" version 1.2
23 characters long description:
Premier plugin resaline

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
Success! There were no dangerous files found in this plugin422 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP59386319
PO File24440
CSS15032
JavaScript112531

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.32
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 functions18100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
2 PNG files occupy 0.32MB with 0.12MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/calendar.png0.69KB0.77KB0.00%
assets/banner-772x250.png328.66KB91.32KB▼ 72.21%