73% vg-postslider

Code Review | VG PostSlider

WordPress plugin VG PostSlider scored 73% from 54 tests.

About plugin

  • Plugin page: vg-postslider
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3.0-4.3.1
  • WordPress version: 6.3.1
  • First release: Dec 1, 2015
  • Latest release: Dec 1, 2015
  • Number of updates: 4
  • Update frequency: N/A
  • Top authors: vinagecko (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

100+ active / 2,942 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▲0.06ms] Passed 4 tests

This is a short check of server-side resources used by VG PostSlider
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0340.78 ▼3.14
Dashboard /wp-admin3.36 ▲0.0547.30 ▼2.04
Posts /wp-admin/edit.php3.47 ▲0.1149.37 ▲1.66
Add New Post /wp-admin/post-new.php5.91 ▲0.0394.14 ▲3.78
Media Library /wp-admin/upload.php3.25 ▲0.0338.57 ▲5.93
About VGPS /wp-admin/edit.php?post_type=vgps&page=vgps_menu_settings3.2735.06
VG New Slider /wp-admin/post-new.php?post_type=vgps3.2840.80
VG PostSlider /wp-admin/edit.php?post_type=vgps3.3243.07

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 26 new files
Database: no new tables, 9 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
vgps_version
category_children
widget_theysaidso_widget
widget_recent-comments
db_upgraded
vgps_customer_type
can_compress_scripts

Browser metrics Passed 4 tests

VG PostSlider: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,096 ▲33915.44 ▲1.147.02 ▲4.9541.71 ▼1.58
Dashboard /wp-admin2,390 ▲2016.68 ▲1.77136.31 ▲15.5341.54 ▼3.48
Posts /wp-admin/edit.php2,296 ▲2073.65 ▲1.5953.40 ▲18.6333.12 ▼1.27
Add New Post /wp-admin/post-new.php1,707 ▲19322.74 ▲5.15623.33 ▼24.8232.74 ▼27.36
Media Library /wp-admin/upload.php1,436 ▲454.48 ▲0.2582.17 ▼18.3942.06 ▼0.20
About VGPS /wp-admin/edit.php?post_type=vgps&page=vgps_menu_settings1,1003.3239.3344.15
VG New Slider /wp-admin/post-new.php?post_type=vgps4,0624.64122.6055.68
VG PostSlider /wp-admin/edit.php?post_type=vgps1,2543.7444.4326.56

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
Please fix the following items
  • The uninstall procedure has failed, leaving 9 options in the database
    • vgps_version
    • db_upgraded
    • widget_recent-posts
    • vgps_customer_type
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • category_children
    • widget_recent-comments
    • can_compress_scripts

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
    • > GET request to /wp-admin/post-new.php?post_type=vgps
    • > Warning in wp-content/plugins/vg-postslider/includes/vgps-functions.php+42
    scandir(wp-content/themes/twentytwentyone/vgps-themes): failed to open dir: No such file or directory
    • > GET request to /wp-admin/post-new.php?post_type=vgps
    • > Warning in wp-content/plugins/vg-postslider/includes/vgps-functions.php+42
    scandir(): (errno 2): No such file or directory
    • > GET request to /wp-admin/post-new.php?post_type=vgps
    • > Warning in wp-content/plugins/vg-postslider/includes/vgps-functions.php+44
    Invalid argument supplied for foreach()
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=vgps
    • > Notice in wp-content/plugins/vg-postslider/includes/vgps-functions.php+20
    Undefined variable: return

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/vg-postslider/vgps-settings.php
  • 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/vg-postslider/includes/vgps-meta.php:35

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 97% from 29 tests

readme.txt 94% 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
These attributes need your attention:
  • Plugin Name: Please specify the plugin name on the first line ( === vg-postslider === )
The official readme.txt might help

vg-postslider/vg-postslider.php Passed 13 tests

Analyzing the main PHP file in "VG PostSlider" version 1.0
114 characters long description:
Responsive & Flexible Post Slider for WordPress. Unlimited slider anywhere via short-codes and easy admin setting.

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
No dangerous file extensions were detected5,610 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript31,2699343,728
PHP5300591,353
CSS31321529

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.29
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%
Functions17
▷ Named functions17100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
includes/images/icon-carousel.png2.78KB0.11KB▼ 96.10%