78% post-slider-carousel

Code Review | Post Sliders & Post Grids

WordPress plugin Post Sliders & Post Grids scored78%from 54 tests.

About plugin

  • Plugin page: post-slider-carousel
  • Plugin version: 1.0.20
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-6.3
  • WordPress version: 6.3.1
  • First release: Feb 7, 2017
  • Latest release: Sep 17, 2023
  • Number of updates: 46
  • Update frequency: every 52.4 days
  • Top authors: nik00726 (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

1,000+ active /52,633 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.42MB] [CPU: ▲2.52ms] Passed 4 tests

Analyzing server-side resources used by Post Sliders & Post Grids
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.88 ▲0.4247.76 ▲5.00
Dashboard /wp-admin3.73 ▲0.4353.30 ▲4.42
Posts /wp-admin/edit.php3.84 ▲0.4953.12 ▲2.92
Add New Post /wp-admin/post-new.php6.31 ▲0.42103.27 ▲4.70
Media Library /wp-admin/upload.php3.65 ▲0.4238.38 ▼1.96
Post Slider & Grid /wp-admin/admin.php?page=psc_post_slider_carousel3.6649.91
Preview Post Grid /wp-admin/admin.php?page=psc_post_slider_grid_preview3.7176.30
Post Grid Settings /wp-admin/admin.php?page=psc_post_slider_grid3.6642.57
Preview Slider /wp-admin/admin.php?page=psc_post_slider_carousel_preview3.7342.27

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Post Sliders & Post Grids
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,824 ▲3814.35 ▼0.271.73 ▼0.2638.54 ▼5.49
Dashboard /wp-admin2,233 ▲565.64 ▼0.0294.27 ▲0.9637.77 ▼2.52
Posts /wp-admin/edit.php2,135 ▲351.95 ▼0.0433.11 ▼7.7434.46 ▼4.73
Add New Post /wp-admin/post-new.php1,554 ▲2823.26 ▼0.19610.22 ▼22.7251.29 ▼11.39
Media Library /wp-admin/upload.php1,438 ▲384.22 ▲0.06102.31 ▼7.5454.16 ▲9.23
Post Slider & Grid /wp-admin/admin.php?page=psc_post_slider_carousel2,1235.06101.6174.60
Preview Post Grid /wp-admin/admin.php?page=psc_post_slider_grid_preview1,1853.4843.3579.78
Post Grid Settings /wp-admin/admin.php?page=psc_post_slider_grid2,4735.90114.3965.59
Preview Slider /wp-admin/admin.php?page=psc_post_slider_carousel_preview1,0993.2646.8875.83

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • This plugin did not uninstall successfully, leaving 10 options in the database
    • widget_theysaidso_widget
    • psc_pgrid_settings
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • psc_slider_settings
    • psc_messages
    • db_upgraded
    • theysaidso_admin_options
    • category_children

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not 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_theme_support() in wp-content/plugins/post-slider-carousel/post-slider-carousel.php:14

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
These are user-side errors you should fix
    • > GET request to /wp-admin/admin.php?page=psc_post_slider_carousel_preview
    • > Javascript (severe) in unknown
    /wp-admin/admin.php?page=psc_post_slider_carousel_preview 223:78 Uncaught SyntaxError: Unexpected token ','

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% 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
Attributes that need to be fixed:
  • Screenshots: A description for screenshot #9 is missing in post-slider-carousel/assets to your readme.txt
  • Tags: You are using too many tags: 12 tag instead of maximum 10
Please take inspiration from this readme.txt

post-slider-carousel/post-slider-carousel.php 92% from 13 tests

The main file in "Post Sliders & Post Grids" v. 1.0.20 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Description: Please don't use more than 140 characters for the plugin description (currently 175 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected6,449 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP1757492,450
JavaScript33446542,293
CSS477331,051
SVG100655

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.30
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%
Functions26
▷ Named functions2492.31%
▷ Anonymous functions27.69%
Constants0
▷ Global constants00.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
16 PNG files occupy 0.11MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/vl-box/playico.png1.35KB1.32KB▼ 2.10%
images/vl-box/controls.png1.33KB1.42KB0.00%
images/vl-box/playico2.png0.93KB0.91KB▼ 2.41%
images/g-suite-promo-code-4.png59.03KB17.19KB▼ 70.88%
images/vl-box/player_play.png1.40KB1.36KB▼ 3.20%