99% ce-scroll-to-top

Code Review | CEX Scroll To Top

WordPress plugin CEX Scroll To Top scored 99% from 54 tests.

About plugin

  • Plugin page: ce-scroll-to-top
  • Plugin version: 1.4.3
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.7
  • WordPress version: 5.8.1
  • First release: Sep 13, 2014
  • Latest release: May 16, 2021
  • Number of updates: 12
  • Update frequency: every 203.2 days
  • Top authors: shohag121 (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active / 683 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.25MB] [CPU: ▼137.09ms] Passed 4 tests

Analyzing server-side resources used by CEX Scroll To Top
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.07 ▲0.3536.71 ▲12.15
Dashboard /wp-admin3.34 ▲0.2947.19 ▲3.90
Posts /wp-admin/edit.php3.39 ▲0.2843.55 ▼2.19
Add New Post /wp-admin/post-new.php5.64 ▲0.2089.76 ▼553.84
Media Library /wp-admin/upload.php3.22 ▲0.2233.73 ▲3.79

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 51 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for CEX Scroll To Top
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,835 ▲22916.25 ▲0.3215.77 ▲8.2146.06 ▼1.25
Dashboard /wp-admin2,991 ▲575.85 ▼0.13127.33 ▼17.38104.43 ▼12.63
Posts /wp-admin/edit.php2,778 ▲392.72 ▲0.0266.66 ▲2.2697.44 ▲15.34
Add New Post /wp-admin/post-new.php1,700 ▲2818.83 ▼0.23371.86 ▼0.70105.14 ▼7.52
Media Library /wp-admin/upload.php1,784 ▼265.02 ▲0.03151.61 ▲9.76115.55 ▲1.51

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstaller ran successfully

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
4 plugin tags: scroll to top, scroll, jquery scroll to top, scroll up

ce-scroll-to-top/ce-scroll-to-top.php 85% from 13 tests

This is the main PHP file of "CEX Scroll To Top" version 1.4.3, 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:
  • Domain Path: The domain path points to an invalid folder, "/languages" does not exist
  • Requires at least: Required version does not match the one declared in readme.txt ("4.0" instead of "5.0")

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
Everything looks great! No dangerous files found in this plugin19,771 lines of code in 36 files:
LanguageFilesBlank linesComment linesLines of code
SVG3009,552
CSS153,670608,117
PHP134527911,843
Markdown1650179
JSON20067
JavaScript20713

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity25.22
▷ Minimum class complexity1.00
▷ Maximum class complexity70.00
Average method complexity2.83
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes9
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes111.11%
Methods120
▷ Static methods54.17%
▷ Public methods8268.33%
▷ Protected methods65.00%
▷ Private methods3226.67%
Functions3
▷ Named functions266.67%
▷ Anonymous functions133.33%
Constants6
▷ Global constants583.33%
▷ Class constants116.67%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin