78% query-slideshow

Code Review | Query Slideshow

WordPress plugin Query Slideshow scored78%from 54 tests.

About plugin

  • Plugin page: query-slideshow
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Feb 26, 2012
  • Latest release: Sep 5, 2014
  • Number of updates: 9
  • Update frequency: every 111.9 days
  • Top authors: daggerhart (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /2,066 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.02MB] [CPU: ▼7.72ms] Passed 4 tests

A check of server-side resources used by Query Slideshow
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0240.72 ▼0.14
Dashboard /wp-admin3.32 ▲0.0250.84 ▼0.67
Posts /wp-admin/edit.php3.37 ▲0.0252.50 ▲1.41
Add New Post /wp-admin/post-new.php5.90 ▲0.0296.10 ▼10.37
Media Library /wp-admin/upload.php3.25 ▲0.0239.37 ▼19.71

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
db_upgraded
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Query Slideshow
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.21 ▼1.291.80 ▼0.3045.03 ▲2.49
Dashboard /wp-admin2,209 ▲244.80 ▼0.07111.44 ▲2.7938.10 ▼5.08
Posts /wp-admin/edit.php2,089 ▼02.01 ▲0.0039.47 ▲3.8336.23 ▼0.86
Add New Post /wp-admin/post-new.php1,514 ▼1917.59 ▼5.51685.63 ▲0.5260.87 ▲3.03
Media Library /wp-admin/upload.php1,385 ▼04.30 ▲0.03100.97 ▼21.6345.99 ▼1.86

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% 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 take a closer look at the following
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/query-slideshow/templates/query-slideshow.php
  • 7× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Notice
      Undefined variable: rows in wp-content/plugins/query-slideshow/templates/query-slideshow.php on line 18
    • > PHP Notice
      Undefined variable: style_settings in wp-content/plugins/query-slideshow/templates/query-slideshow.php on line 14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/query-slideshow/query-slideshow.php:45
    • > PHP Notice
      Undefined variable: slug in wp-content/plugins/query-slideshow/templates/query-slideshow.php on line 17
    • > PHP Warning
      Invalid argument supplied for foreach() in wp-content/plugins/query-slideshow/templates/query-slideshow.php on line 18
    • > PHP Notice
      Undefined variable: slug in wp-content/plugins/query-slideshow/templates/query-slideshow.php on line 14
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/query-slideshow/templates/query-slideshow.php on line 14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
These attributes need to be fixed:
  • Requires at least: Version not formatted correctly
  • Screenshots: Screenshot #1 (Slideshow Settings) image required
The official readme.txt is a good inspiration

query-slideshow/query-slideshow.php Passed 13 tests

"Query Slideshow" version 1.2's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
89 characters long description:
Query Slideshow is a plugin that adds 'Slideshow' as a Template Style for Query Wrangler.

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
Everything looks great! No dangerous files found in this plugin1,572 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript21511401,458
PHP21950114

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.27
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions5
▷ Named functions5100.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
1 PNG file occupies 0.12MB with 0.08MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png127.86KB46.70KB▼ 63.48%