83% eit-scroll-to-top

Code Review | EIT Scroll to top

WordPress plugin EIT Scroll to top scored83%from 54 tests.

About plugin

  • Plugin page: eit-scroll-to-top
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-3.5.1
  • WordPress version: 6.3.1
  • First release: Nov 26, 2014
  • Latest release: Nov 26, 2014
  • Number of updates: 2
  • Update frequency: every 3.5 days
  • Top authors: exclusiveitech (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /768 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.01MB] [CPU: ▼4.06ms] Passed 4 tests

This is a short check of server-side resources used by EIT Scroll to top
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.91 ▼2.32
Dashboard /wp-admin3.31 ▲0.0147.57 ▼0.27
Posts /wp-admin/edit.php3.37 ▲0.0148.12 ▼2.07
Add New Post /wp-admin/post-new.php5.89 ▲0.0187.79 ▼11.58
Media Library /wp-admin/upload.php3.24 ▲0.0140.14 ▲6.02

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for EIT Scroll to top
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,902 ▲15613.68 ▼1.136.09 ▲4.1444.83 ▼0.52
Dashboard /wp-admin2,213 ▲284.88 ▼1.00106.67 ▲4.7440.58 ▼4.58
Posts /wp-admin/edit.php2,099 ▲102.03 ▼0.0236.74 ▼2.7633.12 ▼3.85
Add New Post /wp-admin/post-new.php1,520 ▼023.44 ▼0.03688.31 ▲57.5759.24 ▲13.93
Media Library /wp-admin/upload.php1,398 ▲104.15 ▲0.0098.45 ▲1.0045.95 ▲3.44

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not 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 take a closer look at the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/eit-scroll-to-top/scroll-up.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Screenshots: Screenshot #1 (Scroll to top arrow on bottom right) image required
  • Donate link: Please fix this invalid URI: ""
You can take inspiration from this readme.txt

eit-scroll-to-top/scroll-up.php 92% from 13 tests

This is the main PHP file of "EIT Scroll to top" version 1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("eit-scroll-to-top.php" instead of "scroll-up.php")

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
Good job! No executable or dangerous file extensions detected33 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP151221
CSS1008
JavaScript28234

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No cyclomatic complexity issues were 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%
Functions4
▷ Named functions4100.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
2 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png27.12KB11.36KB▼ 58.10%
css/img/arrow.png3.41KB0.87KB▼ 74.53%