72% superslider-image

Code Review | SuperSlider-Image

WordPress plugin SuperSlider-Image scored 72% from 54 tests.

About plugin

  • Plugin page: superslider-image
  • Plugin version: 2.0
  • PHP version: 7.4.16
  • WordPress version: 5.9.2
  • First release: Jun 22, 2010
  • Latest release: Jan 17, 2013
  • Number of updates: 24
  • Update frequency: every 40.1 days
  • Top authors: Daiv (100%)

Code review

54 tests

User reviews

1 review

Install metrics

50+ active / 8,770 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼296.13ms] Passed 4 tests

A check of server-side resources used by SuperSlider-Image
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.60 ▲0.0957.38 ▼0.79
Dashboard /wp-admin3.45 ▲0.0438.65 ▲2.56
Posts /wp-admin/edit.php3.67 ▲0.0341.76 ▲2.65
Add New Post /wp-admin/post-new.php6.91 ▼0.0599.08 ▼1,186.16
Media Library /wp-admin/upload.php3.32 ▲0.0326.06 ▼0.11
SuperSlider-Image /wp-admin/options-general.php?page=superslider-image3.4926.93

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 24 new files
Database: no new tables, 1 new option
New WordPress options
ssImage_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for SuperSlider-Image
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,812 ▲5816.20 ▲0.215.89 ▼1.002.99 ▲0.36
Dashboard /wp-admin2,906 ▲196.48 ▼0.09128.04 ▼11.02159.18 ▲2.27
Posts /wp-admin/edit.php2,693 ▲53.42 ▼0.0161.31 ▼0.97140.74 ▼2.53
Add New Post /wp-admin/post-new.php1,697 ▼5522.09 ▲0.75406.62 ▼46.23160.39 ▲1.67
Media Library /wp-admin/upload.php1,700 ▼55.71 ▼0.02135.37 ▼6.99190.52 ▲4.94
SuperSlider-Image /wp-admin/options-general.php?page=superslider-image2,3273.2064.36142.86

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 1 option in the database
    • ssImage_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
These server-side errors were triggered
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/options-general.php?page=superslider-image
    • > Notice in wp-content/plugins/superslider-image/admin/superslider-image-ui.php+562
    Trying to access array offset on value of type bool

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/superslider-image/admin/tinymce/plugins/ss-image/ss_image_tinymce.php
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/superslider-image/superslider-image.php:45
    • > PHP Fatal error
      Uncaught Error: Call to undefined function current_user_can() in wp-content/plugins/superslider-image/admin/superslider-image-ui.php:23

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 81% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Requires at least: Invalid version format
  • Tags: Too many tags (14 tag instead of maximum 10); only the first 5 tags are used in your directory listing
  • Screenshots: Screenshot #1 (![SuperSlider-Image options](screenshot-2.png "SuperSlider-Image options")) image missing
The official readme.txt might help

superslider-image/superslider-image.php 92% from 13 tests

The entry point to "SuperSlider-Image" version 2.0 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 253 characters long)

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
There were no executable files found in this plugin1,376 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
PHP318782881
CSS3130182
JavaScript101832169
PO File15660144

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity60.00
▷ Minimum class complexity60.00
▷ Maximum class complexity60.00
Average method complexity3.81
▷ Minimum method complexity1.00
▷ Maximum method complexity40.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods21
▷ Static methods00.00%
▷ Public methods21100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
3 PNG files occupy 0.11MB with 0.05MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/img/logo_superslider.png4.67KB2.61KB▼ 44.16%
screenshot-1.png104.70KB34.99KB▼ 66.58%
admin/tinymce/plugins/ss-image/img/ss-image-icon.png0.52KB0.32KB▼ 38.06%