78% neo-bootstrap-carousel

Code Review | NEO Bootstrap Carousel

WordPress plugin NEO Bootstrap Carousel scored78%from 54 tests.

About plugin

  • Plugin page: neo-bootstrap-car...
  • Plugin version: 1.4.3
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-5.4.1
  • WordPress version: 6.3.1
  • First release: Jul 31, 2016
  • Latest release: Apr 30, 2020
  • Number of updates: 24
  • Update frequency: every 57.1 days
  • Top authors: pixelspress (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

80+ active /5,007 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.14MB] [CPU: ▲4.67ms] 75% from 4 tests

This is a short check of server-side resources used by NEO Bootstrap Carousel
Please take the time to fix the following items
  • CPU: Total CPU usage should be kept under 500.00ms (currently 502.56ms on /wp-admin/admin.php?page=neo-bootstrap-carousel-settings)
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.1254.46 ▲8.62
Dashboard /wp-admin3.44 ▲0.1467.15 ▲12.34
Posts /wp-admin/edit.php3.54 ▲0.1861.36 ▲6.27
Add New Post /wp-admin/post-new.php6.08 ▲0.19100.35 ▼3.06
Media Library /wp-admin/upload.php3.34 ▲0.1144.39 ▲6.83
System Requirements /wp-admin/admin.php?page=neo-bootstrap-carousel-system-requirements3.41495.50
Help /wp-admin/admin.php?page=neo-bootstrap-carousel-help3.39490.60
Sliders /wp-admin/edit.php?post_type=neo_carousel3.3948.62
Settings /wp-admin/admin.php?page=neo-bootstrap-carousel-settings3.40502.56
Welcome /wp-admin/admin.php?page=neo-bootstrap-carousel-welcome3.40496.68
Changelog /wp-admin/admin.php?page=neo-bootstrap-carousel-changelog3.38486.23

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 64 new files
Database: no new tables, 10 new options
New WordPress options
widget_theysaidso_widget
nbc_design_settings
widget_recent-posts
widget_recent-comments
nbc_advanced_settings
nbc_general_settings
can_compress_scripts
theysaidso_admin_options
_nbc_plugin_version
db_upgraded

Browser metrics Passed 4 tests

NEO Bootstrap Carousel: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,240 ▲47923.81 ▲9.21208.43 ▲206.4890.07 ▲46.96
Dashboard /wp-admin2,383 ▲2096.43 ▲0.73100.01 ▼0.7936.76 ▼9.43
Posts /wp-admin/edit.php2,322 ▲2193.59 ▲1.5652.00 ▲9.3030.87 ▼7.39
Add New Post /wp-admin/post-new.php6,237 ▲4,71119.00 ▲1.44885.18 ▲180.4538.42 ▼22.61
Media Library /wp-admin/upload.php1,462 ▲624.46 ▲0.2884.94 ▼24.1543.22 ▼0.42
System Requirements /wp-admin/admin.php?page=neo-bootstrap-carousel-system-requirements1,1983.3638.5479.08
Help /wp-admin/admin.php?page=neo-bootstrap-carousel-help1,1633.3039.8880.88
Sliders /wp-admin/edit.php?post_type=neo_carousel1,2883.8046.3428.07
Settings /wp-admin/admin.php?page=neo-bootstrap-carousel-settings1,5763.5750.7086.17
Welcome /wp-admin/admin.php?page=neo-bootstrap-carousel-welcome1,2773.3441.2896.21
Changelog /wp-admin/admin.php?page=neo-bootstrap-carousel-changelog1,2813.2640.8081.65

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • The uninstall procedure has failed, leaving 10 options in the database
    • nbc_design_settings
    • theysaidso_admin_options
    • nbc_advanced_settings
    • db_upgraded
    • widget_theysaidso_widget
    • nbc_general_settings
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • _nbc_plugin_version

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP 0% 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 take a closer look at the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/neo-bootstrap-carousel/admin/partials/meta-box/neo-bootstrap-carousel-media-display.php
  • 36× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/neo-bootstrap-carousel/includes/admin/settings/class-neo-bootstrap-carousel-general.php:34
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/neo-bootstrap-carousel/admin/partials/neo-bootstrap-carousel-help.php:17
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/neo-bootstrap-carousel/public/partials/neo-bootstrap-carousel-public-display.php on line 15
    • > PHP Notice
      Undefined variable: neo_bootstrap_carousel in wp-content/plugins/neo-bootstrap-carousel/admin/partials/meta-box/neo-bootstrap-carousel-media-display.php on line 18
    • > PHP Notice
      Undefined variable: slide_data in wp-content/plugins/neo-bootstrap-carousel/public/partials/neo-bootstrap-carousel-public-display.php on line 34
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/neo-bootstrap-carousel/includes/admin/class-neo-bootstrap-carousel-changelog.php:34
    • > PHP Warning
      count(): Parameter must be an array or an object that implements Countable in wp-content/plugins/neo-bootstrap-carousel/public/partials/neo-bootstrap-carousel-public-display.php on line 34
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/neo-bootstrap-carousel/includes/class-neo-bootstrap-carousel-meta-box.php:131
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/neo-bootstrap-carousel/includes/admin/class-neo-bootstrap-carousel-help.php:34
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/neo-bootstrap-carousel/includes/functions/neo-bootstrap-carousel-formatting-functions.php:90

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)
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
4 plugin tags: responsive content slideshow, responsive slider, wordpress responsive bootstrap carousel, wordpress horizontal slider

neo-bootstrap-carousel/neo-bootstrap-carousel.php Passed 13 tests

The primary PHP file in "NEO Bootstrap Carousel" version 1.4.3 is used by WordPress to initiate all plugin functionality
107 characters long description:
A clean, simple & robust implementation of the Twitter Bootstrap Carousel in WordPress site in elegant way.

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
Good job! No executable or dangerous file extensions detected12,343 lines of code in 46 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript41,4124475,556
CSS35311404,925
PHP373671,3811,849
SVG21013

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity5.21
▷ Minimum class complexity1.00
▷ Maximum class complexity20.00
Average method complexity2.13
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes19
▷ Abstract classes15.26%
▷ Concrete classes1894.74%
▷ Final classes00.00%
Methods71
▷ Static methods68.45%
▷ Public methods6692.96%
▷ Protected methods00.00%
▷ Private methods57.04%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.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
7 PNG files occupy 0.05MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/images/neo-bootstrap-carousel-logo.png23.61KB9.56KB▼ 59.52%
admin/images/design-settings.png6.67KB3.08KB▼ 53.83%
admin/images/rating-box/heart.png8.04KB3.92KB▼ 51.15%
admin/images/nbc-icon.png1.09KB0.23KB▼ 79.04%
admin/images/rating-box/star.png8.88KB4.00KB▼ 54.94%