10% kiwi-com-widget

Code Review | Cheap Flights By Kiwi.com

WordPress plugin Cheap Flights By Kiwi.com scored10%from 54 tests.

About plugin

  • Plugin page: kiwi-com-widget
  • Plugin version: 1.1.1
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.8
  • WordPress version: 6.3.1
  • First release: Dec 7, 2021
  • Latest release: Jun 19, 2023
  • Number of updates: 8
  • Update frequency: every 70.4 days
  • Top authors: tequilawidget (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

50+ active /1,104 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
You still need to fix the following installer errors
  • Install procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/kiwi-com-widget/kiwicom-widget.php+60
    Function create_function() is deprecated

Server metrics [RAM: ▼1.94MB] [CPU: ▼59.89ms] Passed 4 tests

An overview of server-side resources used by Cheap Flights By Kiwi.com
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.06 ▼1.405.60 ▼35.10
Dashboard /wp-admin2.08 ▼1.265.80 ▼62.50
Posts /wp-admin/edit.php2.08 ▼1.286.28 ▼43.87
Add New Post /wp-admin/post-new.php2.08 ▼3.815.44 ▼98.09
Media Library /wp-admin/upload.php2.08 ▼1.155.06 ▼30.58
Kiwi.com Widget /wp-admin/options-general.php?page=kiwicom2.085.88

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 19 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_recent-posts
widget_kiwicom-widget
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Cheap Flights By Kiwi.com
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,877 ▲13114.35 ▲0.1525.04 ▲23.1242.56 ▼0.69
Dashboard /wp-admin2,198 ▲185.55 ▼0.1295.04 ▲10.4440.74 ▼5.02
Posts /wp-admin/edit.php2,110 ▲101.94 ▼0.0238.26 ▼3.1535.55 ▼0.32
Add New Post /wp-admin/post-new.php6,198 ▲4,66919.51 ▼3.38925.80 ▲272.9739.74 ▼17.54
Media Library /wp-admin/upload.php1,410 ▲104.17 ▼0.04100.62 ▼3.3942.92 ▼4.80
Kiwi.com Widget /wp-admin/options-general.php?page=kiwicom8012.0026.6334.83

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin cannot be uninstalled
    • > Deprecated in wp-content/plugins/kiwi-com-widget/kiwicom-widget.php+60
    Function create_function() is deprecated
  • Zombie WordPress options detected upon uninstall: 7 options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_kiwicom-widget
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=kiwicom
    • > Deprecated in wp-content/plugins/kiwi-com-widget/kiwicom-widget.php+60
    Function create_function() is deprecated

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/kiwi-com-widget/includes/widget.class.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
8 plugin tags: travel, affiliate, blog, attractions, engagement...

kiwi-com-widget/kiwicom-widget.php 85% from 13 tests

The main file in "Cheap Flights By Kiwi.com" v. 1.1.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("kiwi-com-widget.php" instead of "kiwicom-widget.php")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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
Good job! No executable or dangerous file extensions detected377 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
PHP63569165
JavaScript7214145
JSON10036
Markdown124031

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity2.00
▷ Minimum class complexity1.00
▷ Maximum class complexity3.00
Average method complexity1.25
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods8
▷ Static methods00.00%
▷ Public methods8100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants00.00%
▷ Class constants5100.00%
▷ Public constants5100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG images were found in this plugin