84% wp-nice-scroll

Code Review | WP Nice Scroll

WordPress plugin WP Nice Scroll scored84%from 54 tests.

About plugin

  • Plugin page: wp-nice-scroll
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.5.1
  • WordPress version: 6.3.1
  • First release: May 7, 2016
  • Latest release: May 7, 2016
  • Number of updates: 4
  • Update frequency: N/A
  • Top authors: muhaimin1992 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,020 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.10MB] [CPU: ▼0.70ms] Passed 4 tests

Analyzing server-side resources used by WP Nice Scroll
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0842.24 ▼1.43
Dashboard /wp-admin3.43 ▲0.1353.36 ▼1.30
Posts /wp-admin/edit.php3.54 ▲0.1954.36 ▲5.43
Add New Post /wp-admin/post-new.php5.99 ▲0.1098.09 ▲0.39
Media Library /wp-admin/upload.php3.33 ▲0.1035.82 ▼0.46
WP Nice Scroll Settings /wp-admin/options-general.php?page=settings_api_test3.3337.07

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
db_upgraded
wp_nice_scroll_section
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for WP Nice Scroll
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,974 ▲21314.60 ▲0.223.89 ▲1.7744.74 ▼1.83
Dashboard /wp-admin2,350 ▲1736.33 ▲0.63115.01 ▲26.5639.09 ▼5.11
Posts /wp-admin/edit.php2,281 ▲1783.51 ▲1.4849.07 ▲12.0131.68 ▼6.77
Add New Post /wp-admin/post-new.php1,541 ▲1523.14 ▲5.49641.50 ▼75.0036.34 ▼15.71
Media Library /wp-admin/upload.php1,418 ▲214.35 ▲0.0988.69 ▼15.3143.36 ▼2.09
WP Nice Scroll Settings /wp-admin/options-general.php?page=settings_api_test1,3373.6068.3927.50

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • wp_nice_scroll_section
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% 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
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-nice-scroll/plugin-main-file.php:20

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need to be fixed:
  • Contributors: The plugin contributors field is missing
Please take inspiration from this readme.txt

wp-nice-scroll/plugin-main-file.php 92% from 13 tests

The entry point to "WP Nice Scroll" version 1.0 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("wp-nice-scroll.php" instead of "plugin-main-file.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected601 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP4131192481
JavaScript100120

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity26.00
▷ Minimum class complexity3.00
▷ Maximum class complexity49.00
Average method complexity2.47
▷ Minimum method complexity1.00
▷ Maximum method complexity15.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods34
▷ Static methods00.00%
▷ Public methods34100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.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 were not PNG files found in your plugin