78% wen-logo-slider

Code Review | WEN Logo Slider

WordPress plugin WEN Logo Slider scored78%from 54 tests.

About plugin

  • Plugin page: wen-logo-slider
  • Plugin version: 3.1.0
  • PHP compatiblity: 5.6.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.2
  • WordPress version: 6.3.1
  • First release: Jan 13, 2015
  • Latest release: Jul 5, 2023
  • Number of updates: 44
  • Update frequency: every 70.3 days
  • Top authors: WEN Solutions (61.36%)wenthemes (31.82%)wptravel (11.36%)

Code review

54 tests

User reviews

10 reviews

Install metrics

1,000+ active /59,100 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.28MB] [CPU: ▼6.26ms] Passed 4 tests

This is a short check of server-side resources used by WEN Logo Slider
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.74 ▲0.2838.99 ▼1.81
Dashboard /wp-admin3.58 ▲0.2849.97 ▼0.21
Posts /wp-admin/edit.php3.70 ▲0.3445.14 ▼5.67
Add New Post /wp-admin/post-new.php6.17 ▲0.2984.22 ▼17.28
Media Library /wp-admin/upload.php3.51 ▲0.2836.71 ▼0.28
All Sliders /wp-admin/edit.php?post_type=logo_slider3.5539.71
Add New /wp-admin/post-new.php?post_type=logo_slider3.6047.57

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 62 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-posts
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by WEN Logo Slider
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,960 ▲18913.72 ▼0.935.88 ▲3.6841.88 ▼3.58
Dashboard /wp-admin2,248 ▲605.84 ▼0.0195.07 ▼24.2240.03 ▼2.51
Posts /wp-admin/edit.php2,134 ▲452.03 ▼0.0240.27 ▲4.1932.69 ▼1.93
Add New Post /wp-admin/post-new.php1,559 ▲3923.26 ▲0.14656.00 ▼12.6760.97 ▲1.56
Media Library /wp-admin/upload.php1,433 ▲454.28 ▲0.05103.16 ▼5.1544.03 ▼1.54
Settings /wp-admin/class-wen-logo-slider-admin.php260.440.0914.72
All Sliders /wp-admin/edit.php?post_type=logo_slider1,1301.9430.9930.40
Add New /wp-admin/post-new.php?post_type=logo_slider2,6784.0582.38109.30

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Please fix the following
  • 2× 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/wen-logo-slider/admin/partials/wen-logo-slider-settings.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/wen-logo-slider/admin/partials/wen-logo-slider-slides.php:2

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There are user-side issues you should fix
    • > GET request to /wp-admin/class-wen-logo-slider-admin.php
    • > Network (severe)
    wp-admin/class-wen-logo-slider-admin.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need your attention:
  • Tags: Please delete some tags, you are using 11 tag instead of maximum 10
You can take inspiration from this readme.txt

wen-logo-slider/wen-logo-slider.php 92% from 13 tests

This is the main PHP file of "WEN Logo Slider" version 3.1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
It is important to fix the following:
  • Requires at least: Required version must be the same as the one declared in readme.txt ("4.4.0" instead of "4.4")

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 detected4,356 lines of code in 27 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript79371512,428
PHP153525481,343
CSS410176572
SVG11013

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.34
Average class complexity20.88
▷ Minimum class complexity1.00
▷ Maximum class complexity87.00
Average method complexity3.65
▷ Minimum method complexity1.00
▷ Maximum method complexity49.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods60
▷ Static methods23.33%
▷ Public methods5388.33%
▷ Protected methods00.00%
▷ Private methods711.67%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants8100.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
17 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/images/nav/type-i.png1.80KB1.21KB▼ 32.99%
admin/images/help.png8.58KB3.63KB▼ 57.74%
admin/images/nav/type-iii.png1.94KB0.79KB▼ 59.16%
admin/images/docico.png7.15KB3.26KB▼ 54.48%
vendors/slick-carousel/grabbing.png0.11KB0.14KB0.00%