62% wp-dream-carousel

Code Review | WP Dream Carousel

WordPress plugin WP Dream Carousel scored62%from 54 tests.

About plugin

  • Plugin page: wp-dream-carousel
  • Plugin version: 1.0.1b...
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.8.3
  • WordPress version: 6.3.1
  • First release: Apr 20, 2014
  • Latest release: Apr 26, 2014
  • Number of updates: 8
  • Update frequency: every 1.0 days
  • Top authors: neoloki (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,245 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼1.42MB] [CPU: ▼52.81ms] Passed 4 tests

Server-side resources used by WP Dream Carousel
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.57 ▼0.908.12 ▼40.33
Dashboard /wp-admin2.59 ▼0.729.63 ▼45.92
Posts /wp-admin/edit.php2.59 ▼0.7710.83 ▼35.94
Add New Post /wp-admin/post-new.php2.59 ▼3.308.96 ▼89.05
Media Library /wp-admin/upload.php2.59 ▼0.649.36 ▼27.41
Add New /wp-admin/post-new.php?post_type=wp_dream_carousel2.599.78
Install Plugins /wp-admin/themes.php?page=install-required-plugins2.5910.20
All Carousels /wp-admin/edit.php?post_type=wp_dream_carousel2.599.21

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 47 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

Checking browser requirements for WP Dream Carousel
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,957 ▲19613.52 ▼0.7712.43 ▲10.6942.61 ▼2.23
Dashboard /wp-admin2,259 ▲825.71 ▲0.0487.05 ▼7.4682.20 ▲41.43
Posts /wp-admin/edit.php2,173 ▲702.04 ▲0.0941.36 ▲3.5040.55 ▲4.00
Add New Post /wp-admin/post-new.php1,737 ▲21122.18 ▼1.03724.44 ▲75.3681.92 ▲18.76
Media Library /wp-admin/upload.php1,463 ▲694.27 ▲0.07100.06 ▼4.2174.68 ▲29.13
Add New /wp-admin/post-new.php?post_type=wp_dream_carousel1,5822.6352.7784.02
Install Plugins /wp-admin/themes.php?page=install-required-plugins9802.0525.8227.50
All Carousels /wp-admin/edit.php?post_type=wp_dream_carousel1,1401.9834.8537.50

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • The plugin did not uninstall gracefully
    • > Notice in wp-content/plugins/wp-dream-carousel/public/class-wp-dream-carousel.php+63
    Trying to access array offset on value of type bool
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Smoke test failed, please fix the following
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=wp_dream_carousel
    • > POST request to /wp-admin/admin-ajax.php
    • > Notice in wp-content/plugins/wp-dream-carousel/public/class-wp-dream-carousel.php+63
    Trying to access array offset on value of type bool
    • > GET request to /wp-admin/themes.php?page=install-required-plugins
    • > Warning in wp-content/plugins/wp-dream-carousel/public/class-tgm-plugin-activation.php+1977
    Declaration of TGM_Bulk_Installer_Skin::before() should be compatible with Bulk_Upgrader_Skin::before($title = '')
    • > GET request to /wp-admin/themes.php?page=install-required-plugins
    • > Warning in wp-content/plugins/wp-dream-carousel/public/class-tgm-plugin-activation.php+1999
    Declaration of TGM_Bulk_Installer_Skin::after() should be compatible with Bulk_Upgrader_Skin::after($title = '')
    • > GET request to /wp-admin/themes.php?page=install-required-plugins
    • > 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/themes.php?page=install-required-plugins
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/wp-dream-carousel/parts/meta-boxes/slides-use.php
  • 8× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Notice
      Trying to get property 'ID' of non-object in wp-content/plugins/wp-dream-carousel/parts/meta-boxes/slides-definitions.php on line 9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function piklist() in wp-content/plugins/wp-dream-carousel/parts/settings/wpdc-settings-slider.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/wp-dream-carousel/parts/meta-boxes/slides-images.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function piklist() in wp-content/plugins/wp-dream-carousel/parts/settings/wpdc-settings-general.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/wp-dream-carousel/public/class-tgm-plugin-activation.php:164
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/wp-dream-carousel/parts/meta-boxes/slides-definitions.php:11
    • > PHP Notice
      Trying to get property 'ID' of non-object in wp-content/plugins/wp-dream-carousel/parts/meta-boxes/slides-use.php on line 10
    • > PHP Notice
      Trying to get property 'ID' of non-object in wp-content/plugins/wp-dream-carousel/parts/meta-boxes/slides-images.php on line 9

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention:
  • Plugin Name: You should set the name of your plugin on the first line ( === wp-dream-carousel === )
You can look at the official readme.txt

wp-dream-carousel/wp-dream-carousel.php 85% from 13 tests

This is the main PHP file of "WP Dream Carousel" version 1.0.1b..., providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Version: Use only periods and digits for the version number (ex. "1.0.3" instead of "1.0.1b...")
  • Domain Path: The domain path is invalid: folder "/languages" does not exist

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected2,658 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP114831,0741,419
JavaScript5316303782
CSS2618454
Markdown1103

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity36.50
▷ Minimum class complexity6.00
▷ Maximum class complexity108.00
Average method complexity4.33
▷ Minimum method complexity1.00
▷ Maximum method complexity38.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods64
▷ Static methods710.94%
▷ Public methods5382.81%
▷ Protected methods69.38%
▷ Private methods57.81%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
8 PNG files occupy 0.39MB with 0.23MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-5.png106.76KB36.73KB▼ 65.60%
assets/screenshot-4.png43.91KB15.45KB▼ 64.82%
assets/carousel.png1.08KB0.29KB▼ 73.47%
assets/screenshot-1.png23.10KB9.37KB▼ 59.45%
public/assets/images/nav.png0.78KB0.46KB▼ 40.28%