84% 4-level-slider

Code Review | 4 Level Slider

WordPress plugin 4 Level Slider scored 84% from 54 tests.

About plugin

  • Plugin page: 4-level-slider
  • Plugin version: 1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.4
  • WordPress version: 6.3.1
  • First release: Apr 18, 2020
  • Latest release: Apr 18, 2020
  • Number of updates: 3
  • Update frequency: N/A
  • Top authors: ascdevbh (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 558 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

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

Analyzing server-side resources used by 4 Level Slider
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0540.82 ▼3.20
Dashboard /wp-admin3.38 ▲0.0852.14 ▼18.94
Posts /wp-admin/edit.php3.49 ▲0.1450.55 ▲3.59
Add New Post /wp-admin/post-new.php5.96 ▲0.0791.35 ▼0.55
Media Library /wp-admin/upload.php3.28 ▲0.0537.21 ▲1.59

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for 4 Level Slider
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,091 ▲35615.59 ▲1.045.20 ▲3.1236.16 ▼13.23
Dashboard /wp-admin2,379 ▲1916.67 ▲0.77137.20 ▲18.3636.81 ▼7.17
Posts /wp-admin/edit.php2,294 ▲2263.62 ▲1.6047.16 ▲12.6430.63 ▼2.77
Add New Post /wp-admin/post-new.php1,554 ▲1818.52 ▼4.34567.61 ▼69.3033.43 ▼21.55
Media Library /wp-admin/upload.php1,427 ▲394.35 ▲0.1380.26 ▼21.2241.91 ▼2.05

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
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Almost there! Just fix the following items
  • 4× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/4-level-slider/inc/fls-frontend.php:56
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/4-level-slider/inc/fls-admin.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/4-level-slider/inc/fls-enqueue.php:19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/4-level-slider/four-level-slider.php:18

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

readme.txt Passed 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
5 plugin tags: full-width, slider, four images, free, responsive

4-level-slider/four-level-slider.php 92% from 13 tests

Analyzing the main PHP file in "4 Level Slider" version 1.0
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("4-level-slider.php" instead of "four-level-slider.php")

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
Everything looks great! No dangerous files found in this plugin664 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
CSS2100341
PHP43318273
JavaScript34050

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for 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.31
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
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
There are no PNG files in this plugin