72% vg-postcarousel

Code Review | VG PostCarousel

WordPress plugin VG PostCarousel scored72%from 54 tests.

About plugin

  • Plugin page: vg-postcarousel
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3.0-4.3.1
  • WordPress version: 6.3.1
  • First release: Nov 11, 2015
  • Latest release: Nov 18, 2015
  • Number of updates: 6
  • Update frequency: every 1.2 days
  • Top authors: vinagecko (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

1,000+ active /7,510 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.19MB] [CPU: ▼5.51ms] Passed 4 tests

This is a short check of server-side resources used by VG PostCarousel
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.66 ▲0.1938.35 ▼4.67
Dashboard /wp-admin3.52 ▲0.2148.43 ▼3.09
Posts /wp-admin/edit.php3.63 ▲0.2753.14 ▲7.23
Add New Post /wp-admin/post-new.php6.08 ▲0.1982.65 ▼19.56
Media Library /wp-admin/upload.php3.42 ▲0.1939.49 ▲5.30
About VGPC /wp-admin/edit.php?post_type=vgpc&page=vgpc_menu_settings3.4236.76
VG New Carousel /wp-admin/post-new.php?post_type=vgpc3.4541.23
VG PostCarousel /wp-admin/edit.php?post_type=vgpc3.4940.35

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

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

Browser metrics Passed 4 tests

A check of browser resources used by VG PostCarousel
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,074 ▲30315.33 ▲1.045.03 ▲2.7840.75 ▼1.19
Dashboard /wp-admin2,371 ▲1866.71 ▲1.76137.52 ▲34.8493.64 ▲47.48
Posts /wp-admin/edit.php2,289 ▲1933.60 ▲1.5956.29 ▲14.3172.33 ▲35.68
Add New Post /wp-admin/post-new.php1,562 ▲2923.43 ▲0.27677.19 ▲48.2688.89 ▲33.56
Media Library /wp-admin/upload.php1,425 ▲374.46 ▲0.2685.27 ▼13.5882.38 ▲38.70
About VGPC /wp-admin/edit.php?post_type=vgpc&page=vgpc_menu_settings1,1173.1642.3387.29
VG New Carousel /wp-admin/post-new.php?post_type=vgpc3,4364.26119.2997.08
VG PostCarousel /wp-admin/edit.php?post_type=vgpc1,2623.5147.3861.58

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 9 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • category_children
    • db_upgraded
    • widget_theysaidso_widget
    • vgpc_version
    • widget_recent-posts
    • vgpc_customer_type

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/post-new.php?post_type=vgpc
    • > Warning in wp-content/plugins/vg-postcarousel/includes/vgpc-functions.php+35
    scandir(wp-content/themes/twentytwentyone/vgpc-themes): failed to open dir: No such file or directory
    • > GET request to /wp-admin/post-new.php?post_type=vgpc
    • > Warning in wp-content/plugins/vg-postcarousel/includes/vgpc-functions.php+35
    scandir(): (errno 2): No such file or directory
    • > GET request to /wp-admin/post-new.php?post_type=vgpc
    • > Warning in wp-content/plugins/vg-postcarousel/includes/vgpc-functions.php+37
    Invalid argument supplied for foreach()
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=vgpc
    • > Notice in wp-content/plugins/vg-postcarousel/includes/vgpc-functions.php+13
    Undefined variable: return

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× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/vg-postcarousel/vgpc-settings.php
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/vg-postcarousel/includes/vgpc-meta.php:36

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed:
  • Tags: There are too many tags (12 tag instead of maximum 10)
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === vg-postcarousel === )
You can look at the official readme.txt

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

The main PHP file in "VG PostCarousel" ver. 1.1 adds more information about the plugin and also serves as the entry point for this plugin
108 characters long description:
Post Carousel for Wordpress. You can set unlimited carousel anywhere via short-codes and easy admin setting.

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
Good job! No executable or dangerous file extensions detected2,723 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript3209171,303
PHP5293361,158
CSS41519262

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%
Functions16
▷ Named functions16100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
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%