89% oganro-travel-portal-search-widget-for-hotelbeds-apitude-api

Code Review | Oganro Travel Portal Search Widget for HotelBeds APITUDE API

WordPress plugin Oganro Travel Portal Search Widget for HotelBeds APITUDE API scored89%from 54 tests.

About plugin

  • Plugin page: oganro-travel-por...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-4.8
  • WordPress version: 6.3.1
  • First release: Aug 4, 2016
  • Latest release: Aug 4, 2016
  • Number of updates: 13
  • Update frequency: every 32.4 days
  • Top authors: Oganro (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,790 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.01MB] [CPU: ▼8.63ms] Passed 4 tests

Server-side resources used by Oganro Travel Portal Search Widget for HotelBeds APITUDE API
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.35 ▼4.64
Dashboard /wp-admin3.33 ▼0.0247.23 ▼15.37
Posts /wp-admin/edit.php3.38 ▲0.0250.11 ▲0.40
Add New Post /wp-admin/post-new.php5.91 ▲0.0291.02 ▼14.91
Media Library /wp-admin/upload.php3.25 ▲0.0236.09 ▲2.11

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 35 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Oganro Travel Portal Search Widget for HotelBeds APITUDE API
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲6913.31 ▼0.872.20 ▲0.1542.72 ▲2.65
Dashboard /wp-admin2,221 ▲305.86 ▼0.05100.88 ▼0.4783.90 ▲42.14
Posts /wp-admin/edit.php2,107 ▲181.97 ▼0.0838.53 ▼4.8034.82 ▼2.11
Add New Post /wp-admin/post-new.php1,541 ▲2723.14 ▼0.37707.18 ▲37.1955.26 ▼3.17
Media Library /wp-admin/upload.php1,400 ▲154.15 ▼0.0298.17 ▼1.2571.37 ▲28.21

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP Passed 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
No output text or server-side errors detected on direct access of PHP files

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 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Tags: Please reduce the number of tags, currently 16 tag instead of maximum 10
  • Donate link: Please fix this invalid url: ""
You can look at the official readme.txt

oganro-travel-portal-search-widget-for-hotelbeds-apitude-api/ogn-hxsw-hotelbeds-xml-search-widget.php 92% from 13 tests

This is the main PHP file of "Oganro Travel Portal Search Widget for HotelBeds APITUDE API" version 1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("oganro-travel-portal-search-widget-for-hotelbeds-apitude-api.php" instead of "ogn-hxsw-hotelbeds-xml-search-widget.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected4,006 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript54071831,643
CSS4105571,419
PHP514752656
SVG100288

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.26
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
14 compressed PNG files occupy 0.03MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/images/ui-icons_cc0000_256x240.png3.67KB4.17KB0.00%
css/img/ogn_hxsw_settings.png2.48KB1.40KB▼ 43.41%
css/images/ui-icons_444444_256x240.png3.67KB4.17KB0.00%
css/images/ui-icons_777620_256x240.png3.67KB4.17KB0.00%
css/img/ogn_hxsw_search.png1.66KB1.50KB▼ 9.26%