84% range-slider-addon-for-gravity-forms

Code Review | Range Slider AddOn for Gravity Forms

WordPress plugin Range Slider AddOn for Gravity Forms scored84%from 54 tests.

About plugin

  • Plugin page: range-slider-addo...
  • Plugin version: 1.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.0.2
  • WordPress version: 6.3.1
  • First release: Sep 20, 2022
  • Latest release: Sep 20, 2022
  • Number of updates: 3
  • Update frequency: N/A
  • Top authors: kaisarahmmed (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

600+ active /1,317 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.00MB] [CPU: ▼5.58ms] Passed 4 tests

Server-side resources used by Range Slider AddOn for Gravity Forms
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0138.48 ▼4.65
Dashboard /wp-admin3.31 ▼0.0356.76 ▼10.07
Posts /wp-admin/edit.php3.36 ▲0.0150.77 ▲3.74
Add New Post /wp-admin/post-new.php5.89 ▲0.0198.70 ▼8.79
Media Library /wp-admin/upload.php3.23 ▲0.0140.00 ▲1.20

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 11 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Range Slider AddOn for Gravity Forms
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.27 ▲0.071.79 ▼0.1641.43 ▼2.23
Dashboard /wp-admin2,195 ▲175.61 ▼0.0088.24 ▼29.1739.22 ▼5.16
Posts /wp-admin/edit.php2,103 ▼01.98 ▼0.0140.57 ▲1.6235.23 ▼0.10
Add New Post /wp-admin/post-new.php1,526 ▼223.03 ▲0.18665.61 ▼29.0152.48 ▼23.22
Media Library /wp-admin/upload.php1,397 ▼34.22 ▲0.02101.14 ▼16.9645.12 ▼3.90

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% 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
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Class 'GFForms' not found in wp-content/plugins/range-slider-addon-for-gravity-forms/class-nu-range-slider.php:3

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

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
5 plugin tags: gravity forms, slider input, wordpress slider, gravity form range slider, range slider

range-slider-addon-for-gravity-forms/gf-range-slider.php 85% from 13 tests

The main PHP file in "Range Slider AddOn for Gravity Forms" ver. 1.0 adds more information about the plugin and also serves as the entry point for this plugin
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("range-slider-addon-for-gravity-forms.php" instead of "gf-range-slider.php")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

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 plugin946 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP312432383
JavaScript512393292
CSS2037271

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity12.33
▷ Minimum class complexity2.00
▷ Maximum class complexity25.00
Average method complexity2.36
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods25
▷ Static methods28.00%
▷ Public methods25100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin