89% adl-post-slider

Code Review | Post Slider

WordPress plugin Post Slider scored 89% from 54 tests.

About plugin

  • Plugin page: adl-post-slider
  • Plugin version: 1.6.7
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.6
  • WordPress version: 5.9.2
  • First release: Jul 2, 2016
  • Latest release: Jan 28, 2021
  • Number of updates: 38
  • Update frequency: every 44.1 days
  • Top authors: AdlPlugins (55.26%)aazztech (36.84%)armanul94 (13.16%)

Code review

54 tests

User reviews

2 reviews

Install metrics

3,000+ active / 60,190 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

Analyzing server-side resources used by Post Slider
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0460.13 ▲11.77
Dashboard /wp-admin3.46 ▲0.0533.45 ▲0.43
Posts /wp-admin/edit.php3.69 ▲0.0537.69 ▲0.71
Add New Post /wp-admin/post-new.php6.93 ▼0.0497.25 ▼1,171.62
Media Library /wp-admin/upload.php3.33 ▲0.0425.29 ▼1.23
Add New /wp-admin/post-new.php?post_type=adlpostslider3.6345.02
Usage & Support /wp-admin/edit.php?post_type=adlpostslider&page=usage3.3726.95
All Post Sliders /wp-admin/edit.php?post_type=adlpostslider3.4827.95

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 40 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Post Slider: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,829 ▲7516.14 ▲0.165.85 ▲0.172.61 ▼0.28
Dashboard /wp-admin2,934 ▲806.13 ▼0.03114.28 ▼22.04157.58 ▼10.98
Posts /wp-admin/edit.php2,761 ▲673.26 ▲0.0270.76 ▲6.18153.28 ▲8.35
Add New Post /wp-admin/post-new.php1,688 ▼6416.24 ▼5.34438.41 ▼26.09157.92 ▼2.62
Media Library /wp-admin/upload.php1,738 ▲405.52 ▲0.03146.41 ▼2.22190.10 ▲4.48
Add New /wp-admin/post-new.php?post_type=adlpostslider5,5946.65165.15198.66
Usage & Support /wp-admin/edit.php?post_type=adlpostslider&page=usage1,5394.7570.12114.10
All Post Sliders /wp-admin/edit.php?post_type=adlpostslider1,6855.4677.39115.06

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 0% 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 items
  • 7× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/adl-post-slider/includes/aps-style.php
    • > /wp-content/plugins/adl-post-slider/themes/themea.php
    • > /wp-content/plugins/adl-post-slider/themes/themeb.php
    • > /wp-content/plugins/adl-post-slider/adl-post-slider.php
    • > /wp-content/plugins/adl-post-slider/includes/aps-image-resizer.php
    • > /wp-content/plugins/adl-post-slider/includes/aps-upgrade.php
    • > /wp-content/plugins/adl-post-slider/includes/aps-cpt.php
  • 37× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/adl-post-slider/includes/aps-featured-post.php:4
    • > PHP Notice
      Undefined variable: random_aps_wrapper_id in wp-content/plugins/adl-post-slider/includes/aps-style.php on line 17
    • > PHP Notice
      Undefined variable: nextButton in wp-content/plugins/adl-post-slider/includes/aps-style.php on line 55
    • > PHP Notice
      Undefined variable: prevButton in wp-content/plugins/adl-post-slider/includes/aps-style.php on line 58
    • > PHP Notice
      Undefined variable: random_aps_wrapper_id in wp-content/plugins/adl-post-slider/includes/aps-style.php on line 12
    • > PHP Notice
      Undefined variable: aps_display_img in wp-content/plugins/adl-post-slider/themes/themea.php on line 15
    • > PHP Notice
      Undefined variable: nextButton in wp-content/plugins/adl-post-slider/includes/aps-style.php on line 35
    • > PHP Notice
      Undefined variable: aps_nav_arrow_hover_color in wp-content/plugins/adl-post-slider/includes/aps-style.php on line 65
    • > PHP Notice
      Undefined variable: random_aps_wrapper_id in wp-content/plugins/adl-post-slider/includes/aps-style.php on line 8
    • > PHP Notice
      Undefined variable: nextButton in wp-content/plugins/adl-post-slider/includes/aps-style.php on line 63

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 Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
6 plugin tags: featured post slider, recent post slider, post carousel, popular post slider, responsive post slider...

adl-post-slider/adl-post-slider.php Passed 13 tests

This is the main PHP file of "Post Slider" version 1.6.7, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
109 characters long description:
This excellent plugin allows you to display your posts with a very beautiful slider without coding knowledge.

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
Success! There were no dangerous files found in this plugin2,330 lines of code in 29 files:
LanguageFilesBlank linesComment linesLines of code
PHP194112551,681
CSS78774547
JavaScript2121289
SVG11013

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity17.50
▷ Minimum class complexity1.00
▷ Maximum class complexity34.00
Average method complexity7.60
▷ Minimum method complexity1.00
▷ Maximum method complexity30.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods5
▷ Static methods120.00%
▷ Public methods360.00%
▷ Protected methods00.00%
▷ Private methods240.00%
Functions37
▷ Named functions37100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants8100.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
css/owl.video.play.png4.86KB2.74KB▼ 43.61%