78% banner-display-thumbnail

Code Review | Banner Display Thumbnail

WordPress plugin Banner Display Thumbnail scored78%from 54 tests.

About plugin

  • Plugin page: banner-display-th...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.4
  • WordPress version: 6.3.1
  • First release: Feb 4, 2016
  • Latest release: Feb 3, 2016
  • Number of updates: 2
  • Update frequency: every 0.5 days
  • Top authors: module.express (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,120 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼7.35ms] Passed 4 tests

An overview of server-side resources used by Banner Display Thumbnail
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1144.66 ▼0.21
Dashboard /wp-admin3.40 ▲0.0549.33 ▼10.81
Posts /wp-admin/edit.php3.45 ▲0.0949.53 ▼0.28
Add New Post /wp-admin/post-new.php5.98 ▲0.0986.00 ▼18.11
Media Library /wp-admin/upload.php3.32 ▲0.0938.52 ▲0.40
Gallery showcases /wp-admin/edit.php?post_type=bdt_gallery_slider&page=responsive_gallery-vss-bar-submenu-page3.2933.65
Add New /wp-admin/post-new.php?post_type=bdt_gallery_slider3.4452.23
All Images /wp-admin/edit.php?post_type=bdt_gallery_slider3.3639.40
Gallery Category /wp-admin/edit-tags.php?taxonomy=responsive_bdt_slider-category&post_type=bdt_gallery_slider3.3136.69

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Banner Display Thumbnail
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,951 ▲16513.89 ▼0.2413.86 ▲11.8846.00 ▲6.21
Dashboard /wp-admin2,230 ▲535.51 ▼0.1489.09 ▼6.4940.05 ▲2.14
Posts /wp-admin/edit.php2,138 ▲381.97 ▲0.0135.40 ▼1.7036.51 ▲3.06
Add New Post /wp-admin/post-new.php1,558 ▲3023.20 ▲0.05675.15 ▼2.1355.76 ▲7.25
Media Library /wp-admin/upload.php1,435 ▲354.20 ▲0.1098.98 ▼19.0847.63 ▲0.78
Gallery showcases /wp-admin/edit.php?post_type=bdt_gallery_slider&page=responsive_gallery-vss-bar-submenu-page8132.1527.1630.11
Add New /wp-admin/post-new.php?post_type=bdt_gallery_slider2,3437.66168.7367.37
All Images /wp-admin/edit.php?post_type=bdt_gallery_slider1,1191.9731.2132.59
Gallery Category /wp-admin/edit-tags.php?taxonomy=responsive_bdt_slider-category&post_type=bdt_gallery_slider1,2922.1228.2534.28

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 3× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post_meta() in wp-content/plugins/banner-display-thumbnail/designs/template.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/banner-display-thumbnail/banner-display-thumbnail.php:327
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/banner-display-thumbnail/bdt_gallery_admin_settings_center.php:2

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please fix the following browser errors
    • > GET request to /wp-admin/edit.php?post_type=bdt_gallery_slider&page=responsive_gallery-vss-bar-submenu-page
    • > Network (severe)
    wp-content/plugins/banner-display-thumbnail/images/design-1.jpg - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Please fix the following attributes:
  • Screenshots: Please add images for these screenshots: #1 (Designs Views from admin side), #2 (Catagroies shortcode)
You can look at the official readme.txt

banner-display-thumbnail/banner-display-thumbnail.php Passed 13 tests

The entry point to "Banner Display Thumbnail" version 1.0 is a PHP file that has certain tags in its header comment area
44 characters long description:
A simple Responsive Banner Display Thumbnail

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected3,854 lines of code in 31 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript185493762,266
CSS102541291,299
PHP35925289

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity21.00
▷ Minimum class complexity21.00
▷ Maximum class complexity21.00
Average method complexity2.67
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods12
▷ Static methods00.00%
▷ Public methods12100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
24 PNG files occupy 0.31MB with 0.27MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
themes/light-big/images/left-arrow.png23.34KB0.58KB▼ 97.53%
themes/light/images/up-arrow.png3.31KB0.45KB▼ 86.45%
themes/default-big/images/up-arrow.png3.36KB0.40KB▼ 87.99%
themes/dark-big/images/up-arrow.png3.82KB0.61KB▼ 83.92%
themes/default-big/images/down-arrow.png3.41KB0.43KB▼ 87.40%