10% featured-image-widget-slider

Code Review | Featured Image Widget Slider

WordPress plugin Featured Image Widget Slider scored10%from 54 tests.

About plugin

  • Plugin page: featured-image-wi...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-3.8
  • WordPress version: 6.3.1
  • First release: Apr 21, 2013
  • Latest release: Aug 24, 2014
  • Number of updates: 23
  • Update frequency: every 21.5 days
  • Top authors: CuvixSystem (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

60+ active /10,277 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The following installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/featured-image-widget-slider/widget_slider.php+48
    Methods with the same name as their class will not be constructors in a future version of PHP; Category_Widget has a deprecated constructor

Server metrics [RAM: ▼1.91MB] [CPU: ▼56.30ms] Passed 4 tests

Analyzing server-side resources used by Featured Image Widget Slider
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /2.08 ▼1.385.67 ▼42.27
Dashboard /wp-admin2.10 ▼1.206.13 ▼45.95
Posts /wp-admin/edit.php2.10 ▼1.256.21 ▼48.72
Add New Post /wp-admin/post-new.php2.10 ▼3.785.85 ▼88.24
Media Library /wp-admin/upload.php2.10 ▼1.136.42 ▼27.75

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Featured Image Widget Slider
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,872 ▲11113.86 ▼0.538.90 ▲7.0743.81 ▼0.02
Dashboard /wp-admin2,192 ▲155.57 ▼0.1086.60 ▼5.8639.69 ▲0.24
Posts /wp-admin/edit.php2,097 ▼62.00 ▼0.0139.82 ▲0.0736.03 ▲1.62
Add New Post /wp-admin/post-new.php1,549 ▲2323.44 ▲5.85679.82 ▼52.9353.52 ▲1.32
Media Library /wp-admin/upload.php1,403 ▲64.29 ▲0.07110.27 ▼24.0247.15 ▼9.95

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Uninstall procedure validation failed for this plugin
    • > Deprecated in wp-content/plugins/featured-image-widget-slider/widget_slider.php+48
    Methods with the same name as their class will not be constructors in a future version of PHP; Category_Widget has a deprecated constructor
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_category_slider
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for 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 | 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 fix the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/featured-image-widget-slider/widget_slider.php:21

User-side errors Passed 1 test

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

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
Please fix the following attributes:
  • Donate link: Please fix this invalid URI: ""
You can look at the official readme.txt

featured-image-widget-slider/widget_slider.php 85% from 13 tests

The principal PHP file in "Featured Image Widget Slider" v. 1.0 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 175 characters long)
  • Main file name: The principal plugin file should be the same as the plugin slug ("featured-image-widget-slider.php" instead of "widget_slider.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected454 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript23149309
PHP14824124
CSS15121

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.08
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity2.50
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
2 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png11.74KB5.03KB▼ 57.13%
screenshot-2.png18.51KB10.97KB▼ 40.70%