78% scrolling-anchors

Code Review | Easy Smooth Scroll Links

WordPress plugin Easy Smooth Scroll Links scored78%from 54 tests.

About plugin

  • Plugin page: scrolling-anchors
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 2.6.5-4.5
  • WordPress version: 6.3.1
  • First release: Apr 26, 2017
  • Latest release: Apr 26, 2017
  • Number of updates: 2
  • Update frequency: every 3.5 days
  • Top authors: andrewmatt (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

800+ active /4,868 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▲0.30ms] Passed 4 tests

Server-side resources used by Easy Smooth Scroll Links
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0444.27 ▲6.35
Dashboard /wp-admin3.35 ▲0.0546.33 ▲2.63
Posts /wp-admin/edit.php3.41 ▲0.0442.76 ▼3.82
Add New Post /wp-admin/post-new.php5.94 ▲0.0589.41 ▲0.55
Media Library /wp-admin/upload.php3.28 ▲0.0436.48 ▲1.84
Scroll Anchor Settings /wp-admin/options-general.php?page=scanc-plugin-options3.2929.61

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

Browser metrics Passed 4 tests

Easy Smooth Scroll Links: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,902 ▲14113.79 ▼0.568.91 ▲6.7642.97 ▲1.35
Dashboard /wp-admin2,202 ▲255.58 ▼0.0989.62 ▲2.3741.32 ▲0.29
Posts /wp-admin/edit.php2,104 ▲72.02 ▼0.0134.89 ▼2.9134.15 ▼0.31
Add New Post /wp-admin/post-new.php1,529 ▲323.05 ▲0.04614.01 ▼65.8449.14 ▼11.70
Media Library /wp-admin/upload.php1,401 ▼24.20 ▲0.0394.75 ▼3.7243.81 ▼2.27
Scroll Anchor Settings /wp-admin/options-general.php?page=scanc-plugin-options1,1592.0222.3040.18

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

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=scanc-plugin-options
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=scanc-plugin-options
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.

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
Please fix the following items
  • 2× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/scrolling-anchors/index.php:19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function screen_icon() in wp-content/plugins/scrolling-anchors/options.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 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
These attributes need your attention:
  • Tags: You are using too many tags: 11 tag instead of maximum 10
You can look at the official readme.txt

scrolling-anchors/index.php 85% from 13 tests

The main PHP script in "Easy Smooth Scroll Links" version 1.0 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("scrolling-anchors.php" instead of "index.php")
  • Description: Please don't use more than 140 characters for the plugin description (currently 141 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected403 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP24437270
JavaScript2370133

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.46
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.25
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods4100.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
There were not PNG files found in your plugin