83% best-logo-slider

Code Review | Best Logo Slider

WordPress plugin Best Logo Slider scored83%from 54 tests.

About plugin

  • Plugin page: best-logo-slider
  • Plugin version: 1.0.6
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Sep 29, 2014
  • Latest release: Aug 9, 2023
  • Number of updates: 31
  • Update frequency: every 104.4 days
  • Top authors: wpbean (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

200+ active /32,232 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼4.49ms] Passed 4 tests

Server-side resources used by Best Logo Slider
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0840.04 ▼0.91
Dashboard /wp-admin3.38 ▲0.0746.08 ▼2.77
Posts /wp-admin/edit.php3.43 ▲0.0747.74 ▼3.25
Add New Post /wp-admin/post-new.php5.97 ▲0.0884.48 ▼11.04
Media Library /wp-admin/upload.php3.30 ▲0.0735.80 ▲1.99
Add New Logo /wp-admin/post-new.php?post_type=logo_slider3.3646.63
All Logos /wp-admin/edit.php?post_type=logo_slider3.3537.79

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
db_upgraded
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Best Logo Slider
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,922 ▲17614.11 ▼0.136.64 ▲5.1044.70 ▲4.58
Dashboard /wp-admin2,233 ▲424.85 ▼1.03112.98 ▲5.3142.47 ▲0.94
Posts /wp-admin/edit.php2,116 ▲302.03 ▲0.0638.97 ▲1.0335.44 ▼0.43
Add New Post /wp-admin/post-new.php1,565 ▲5118.49 ▲0.89650.42 ▼59.3049.94 ▼2.99
Media Library /wp-admin/upload.php1,415 ▲304.20 ▼0.0297.59 ▼3.9440.73 ▼4.41
Add New Logo /wp-admin/post-new.php?post_type=logo_slider1,7523.5264.1336.13
All Logos /wp-admin/edit.php?post_type=logo_slider1,0891.9331.0129.91

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
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% 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
Almost there! Just fix the following items
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/best-logo-slider/wpb-bls-shortcodes.php:28
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/best-logo-slider/wpb_metabox.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/best-logo-slider/wpb-scripts.php:7

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that need to be fixed:
  • Tags: You are using too many tags: 28 tag instead of maximum 10
You can look at the official readme.txt

best-logo-slider/main.php 85% from 13 tests

Analyzing the main PHP file in "Best Logo Slider" version 1.0.6
Please make the necessary changes and fix the following:
  • Description: Please don't use more than 140 characters for the plugin description (currently 256 characters long)
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("best-logo-slider.php" instead of "main.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Good job! No executable or dangerous file extensions detected1,767 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript1207171,288
CSS22228298
PHP58397181

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity31.00
▷ Minimum class complexity31.00
▷ Maximum class complexity31.00
Average method complexity7.00
▷ Minimum method complexity1.00
▷ Maximum method complexity27.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods120.00%
▷ Public methods360.00%
▷ Protected methods00.00%
▷ Private methods240.00%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/css/grabbing.png3.26KB1.28KB▼ 60.68%