68% dispongo

Code Review | DISPONGO

WordPress plugin DISPONGO scored68%from 54 tests.

About plugin

  • Plugin page: dispongo
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-4.8
  • WordPress version: 6.3.1
  • First release: Aug 25, 2017
  • Latest release: Aug 25, 2017
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: doblemente (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /964 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

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

Analyzing server-side resources used by DISPONGO
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.05 ▼1.414.74 ▼38.40
Dashboard /wp-admin2.07 ▼1.246.00 ▼40.58
Posts /wp-admin/edit.php2.07 ▼1.296.90 ▼39.63
Add New Post /wp-admin/post-new.php2.07 ▼3.826.53 ▼84.61
Media Library /wp-admin/upload.php2.07 ▼1.165.46 ▼31.72
Dispongo Settings /wp-admin/options-general.php?page=dispongo_plugin_options2.075.69

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 46 new files
Database: no new tables, 19 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_dsp_city_list_widget
widget_theysaidso_widget
widget_dsp_product_detail_widget
widget_dsp_user_login_external_widget
theysaidso_admin_options
db_upgraded
widget_dsp_user_new_form_widget
widget_dsp_continent_list_widget
...

Browser metrics Passed 4 tests

A check of browser resources used by DISPONGO
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,837 ▲8013.25 ▼1.131.91 ▲0.0441.45 ▼7.43
Dashboard /wp-admin2,212 ▲365.84 ▼0.0097.11 ▼2.7635.38 ▼9.55
Posts /wp-admin/edit.php2,095 ▲62.01 ▲0.0040.56 ▼2.4635.96 ▼0.43
Add New Post /wp-admin/post-new.php6,195 ▲4,67523.50 ▲0.27875.63 ▲194.0450.92 ▲0.05
Media Library /wp-admin/upload.php1,394 ▲94.31 ▲0.0395.10 ▼4.9743.90 ▲1.26
Dispongo Settings /wp-admin/options-general.php?page=dispongo_plugin_options7832.0625.7026.88

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • Uninstall procedure had uncaught errors
    • > User notice in wp-includes/functions.php+5905
    Function wp_register_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 dispongo-css handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • Zombie WordPress options detected upon uninstall: 19 options
    • can_compress_scripts
    • widget_dsp_city_list_widget
    • theysaidso_admin_options
    • widget_dsp_country_list_widget
    • widget_dsp_product_detail_widget
    • widget_dsp_product_tab_contents_widget
    • widget_dsp_user_account_widget
    • widget_dsp_product_top_ten_widget
    • widget_dsp_product_list_widget
    • widget_dsp_product_tab_images_widget
    • ...

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User notice in wp-includes/functions.php+5905
    Function wp_register_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 dispongo-css handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > 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 dispongo-css handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_continent_list_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_country_list_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_city_list_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_product_list_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_iframe_includer_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_product_top_ten_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_product_offers_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_product_tab_images_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_product_tab_contents_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_product_detail_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_user_account_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_user_new_form_widget is deprecated since version 4.3.0! Use __construct() instead.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5546
    The called constructor method for WP_Widget class in dsp_user_login_external_widget is deprecated since version 4.3.0! Use __construct() instead.
  • 9 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > Notice in wp-content/plugins/dispongo/dispongo.php+441
    Trying to access array offset on value of type bool
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=dispongo_plugin_options
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.

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
Almost there! Just fix the following items
  • 20× PHP files output non-empty strings when accessed directly via GET requests (only 10 are shown):
    • > /wp-content/plugins/dispongo/widgets/templates/product_offers_widget/default.php
    • > /wp-content/plugins/dispongo/widgets/templates/product_tab_images_widget/default.php
    • > /wp-content/plugins/dispongo/css-dispongo.php
    • > /wp-content/plugins/dispongo/widgets/templates/product_top_ten_widget/default-2.php
    • > /wp-content/plugins/dispongo/widgets/templates/product_list_widget/custom-old.php
    • > /wp-content/plugins/dispongo/widgets/templates/product_top_ten_widget/default.php
    • > /wp-content/plugins/dispongo/widgets/templates/product_offers_widget/default-2.php
    • > /wp-content/plugins/dispongo/widgets/templates/product_list_widget/default-2.php
    • > /wp-content/plugins/dispongo/widgets/templates/country_list_widget/prueba.php
    • > /wp-content/plugins/dispongo/widgets/templates/user_account_widget/default.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
2 plugin tags: dispongo, doblemente

dispongo/dispongo.php Passed 13 tests

The principal PHP file in "DISPONGO" v. 1.0.1 is loaded by WordPress automatically on each request
27 characters long description:
Dispongo Tourism E-Commerce

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected4,104 lines of code in 43 files:
LanguageFilesBlank linesComment linesLines of code
PHP385304103,155
JavaScript217840795
CSS32221154

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.14
Average class complexity8.53
▷ Minimum class complexity1.00
▷ Maximum class complexity19.00
Average method complexity2.19
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes15
▷ Abstract classes00.00%
▷ Concrete classes15100.00%
▷ Final classes00.00%
Methods95
▷ Static methods00.00%
▷ Public methods95100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions43
▷ Named functions43100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.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
2 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
widgets/css/images/rating.png23.28KB0.21KB▼ 99.09%
widgets/css/images/map-marker.png1.03KB1.11KB0.00%