84% photostack-slider

Code Review | PhotoStack Slider

WordPress plugin PhotoStack Slider scored84%from 54 tests.

About plugin

  • Plugin page: photostack-slider
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.6.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.6-6.3
  • WordPress version: 6.3.1
  • First release: Nov 3, 2020
  • Latest release: Sep 5, 2023
  • Number of updates: 7
  • Update frequency: every 148.0 days
  • Top authors: tishonator (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /440 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

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

Analyzing server-side resources used by PhotoStack Slider
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0539.95 ▲2.40
Dashboard /wp-admin3.38 ▲0.0442.57 ▼16.17
Posts /wp-admin/edit.php3.43 ▲0.0746.99 ▲0.86
Add New Post /wp-admin/post-new.php5.98 ▲0.0998.39 ▼1.35
Media Library /wp-admin/upload.php3.30 ▲0.0736.08 ▲2.99

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 16 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for PhotoStack Slider
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲4313.21 ▼1.081.63 ▼0.3341.13 ▲0.72
Dashboard /wp-admin2,217 ▲254.89 ▼0.0695.40 ▼11.1839.71 ▼7.46
Posts /wp-admin/edit.php2,117 ▲282.27 ▲0.2436.02 ▼0.3934.51 ▼0.09
Add New Post /wp-admin/post-new.php1,537 ▲418.11 ▼4.99636.40 ▼37.1361.45 ▲6.18
Media Library /wp-admin/upload.php1,412 ▲274.26 ▲0.0695.59 ▲2.1940.89 ▼3.55

Uninstaller [IO: ▲0.00MB] [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 does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 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/photostack-slider/photostack-slider.php:344

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
5 plugin tags: photo rotate images, photo carousel, jquery photo slider, responsive photo slider, photo slider

photostack-slider/photostack-slider.php Passed 13 tests

The main PHP script in "PhotoStack Slider" version 1.0.1 is automatically included on every request by WordPress
138 characters long description:
Configure a Responsive Photo Stack Slider and Insert it in any Page or Post as a Shortcode. Admin Slide Fields for Title, Text, and Image.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin3,660 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
CSS342262,338
SVG100655
JavaScript58276466
PHP18360201

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.23
Average class complexity21.00
▷ Minimum class complexity21.00
▷ Maximum class complexity21.00
Average method complexity2.43
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods14
▷ Static methods17.14%
▷ Public methods14100.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
There are no PNG files in this plugin