10% wp-localscroll

Code Review | WP LocalScroll

WordPress plugin WP LocalScroll scored10%from 54 tests.

About plugin

  • Plugin page: wp-localscroll
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.8
  • WordPress version: 6.3.1
  • First release: Jan 7, 2014
  • Latest release: Jan 9, 2014
  • Number of updates: 6
  • Update frequency: every 0.5 days
  • Top authors: philiprabbett (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

100+ active /3,473 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The following installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Notice in wp-includes/plugin.php+1001
    Undefined offset: 0

Server metrics [RAM: ▼1.96MB] [CPU: ▼48.75ms] Passed 4 tests

An overview of server-side resources used by WP LocalScroll
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.446.28 ▼29.10
Dashboard /wp-admin2.05 ▼1.266.64 ▼51.54
Posts /wp-admin/edit.php2.05 ▼1.316.29 ▼38.31
Add New Post /wp-admin/post-new.php2.05 ▼3.846.59 ▼76.03
Media Library /wp-admin/upload.php2.05 ▼1.186.59 ▼27.03
Rabbett Designs /wp-admin/plugins.php?page=rabbett_designs2.057.18

Server storage [IO: ▲0.02MB] [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: 6 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
wp_localscroll_settings

Browser metrics Passed 4 tests

An overview of browser requirements for WP LocalScroll
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,878 ▲11713.40 ▼0.899.08 ▲7.4938.71 ▼3.07
Dashboard /wp-admin2,199 ▲195.58 ▼0.0490.91 ▼10.1740.05 ▼4.07
Posts /wp-admin/edit.php2,107 ▲42.02 ▲0.0839.77 ▼1.9436.48 ▼2.16
Add New Post /wp-admin/post-new.php1,532 ▲123.19 ▲0.07674.51 ▲14.5454.00 ▼1.40
Media Library /wp-admin/upload.php1,401 ▲14.25 ▲0.0597.17 ▲1.5240.61 ▲0.21
Rabbett Designs /wp-admin/plugins.php?page=rabbett_designs1,0612.2535.9725.26

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
  • This plugin did not uninstall without warnings or errors
    • > Notice in wp-includes/plugin.php+1001
    Undefined offset: 0
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • wp_localscroll_settings
    • db_upgraded
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Smoke test failed, please fix the following
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/plugins.php?page=rabbett_designs
    • > Notice in wp-includes/plugin.php+1004
    Undefined offset: 0
    • > GET request to /wp-admin/plugins.php?page=rabbett_designs
    • > Warning in wp-includes/class-wp-hook.php+310
    call_user_func_array() expects parameter 1 to be a valid callback, no array or string given
  • 15 occurences, only the last one shown
    • > GET request to /wp-admin/plugins.php?page=rabbett_designs
    • > Notice in wp-content/plugins/wp-localscroll/wp-localscroll.php+201
    Undefined variable: html

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/wp-localscroll/inc/class-rd-plugin-settings.php:138
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/wp-localscroll/wp-localscroll.php:32

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
10 plugin tags: navigation, scroll, link, anchor, links...

wp-localscroll/wp-localscroll.php 92% from 13 tests

The main file in "WP LocalScroll" v. 1.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Description: Please don't use more than 140 characters for the plugin description (currently 262 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin289 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP261117287
JavaScript20142

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity4.00
▷ Minimum class complexity4.00
▷ Maximum class complexity4.00
Average method complexity1.38
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods8
▷ Static methods00.00%
▷ Public methods8100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions15
▷ Named functions15100.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