94% wp-scroll

Code Review | WP Scroll

WordPress plugin WP Scroll scored 94% from 53 tests.

About plugin

  • Plugin page: wp-scroll
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.0
  • WordPress version: 5.8.1
  • First release: Mar 19, 2016
  • Latest release: Dec 12, 2018
  • Number of updates: 6
  • Update frequency: every 166.5 days
  • Top authors: hmbashar (100%)

Code review

53 tests

User reviews

1 review

Install metrics

10+ active / 503 total downloads

Benchmarks

Plugin footprint Passed 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.00MB] [CPU: ▼274.01ms] Passed 4 tests

Server-side resources used by WP Scroll
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.0130.49 ▲1.26
Dashboard /wp-admin3.06 ▲0.0140.04 ▼0.11
Posts /wp-admin/edit.php3.11 ▲0.0137.46 ▼8.95
Add New Post /wp-admin/post-new.php5.42 ▼0.0184.70 ▼1,081.72
Media Library /wp-admin/upload.php3.00 ▼0.0031.07 ▼5.26

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Checking browser requirements for WP Scroll
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,819 ▲21316.62 ▲0.9711.32 ▲1.8751.93 ▲6.09
Dashboard /wp-admin2,962 ▲1096.07 ▲0.25134.80 ▲3.18100.78 ▼3.00
Posts /wp-admin/edit.php2,703 ▼32.68 ▼0.0166.57 ▲2.0285.24 ▼6.97
Add New Post /wp-admin/post-new.php1,588 ▼45021.46 ▲2.22262.49 ▼104.6993.50 ▼13.84
Media Library /wp-admin/upload.php1,772 ▼05.00 ▼0.02139.50 ▼6.88105.06 ▼18.69

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
This plugin's uninstaller ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wp-scroll/index.php:22

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: Screenshot #2 (screenshot-2) image required
The official readme.txt is a good inspiration

wp-scroll/index.php 92% from 13 tests

"WP Scroll" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("wp-scroll.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin39 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP112816
JavaScript16014
CSS1009

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.00
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%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 1 test

Image compression Passed 1 test

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG images were found in this plugin