84% slide-to-subscribe

Code Review | Slide to Subscribe

WordPress plugin Slide to Subscribe scored 84% from 54 tests.

About plugin

  • Plugin page: slide-to-subscribe
  • Plugin version: 1.1
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-5.3.2
  • WordPress version: 6.3.1
  • First release: Feb 22, 2020
  • Latest release: Mar 1, 2020
  • Number of updates: 5
  • Update frequency: every 2.2 days
  • Top authors: andreitp1 (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

10+ active / 686 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.03MB] [CPU: ▼1.59ms] Passed 4 tests

A check of server-side resources used by Slide to Subscribe
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0341.62 ▼2.96
Dashboard /wp-admin3.34 ▲0.0447.67 ▼4.07
Posts /wp-admin/edit.php3.39 ▲0.0350.29 ▲0.74
Add New Post /wp-admin/post-new.php5.92 ▲0.0397.84 ▲6.40
Media Library /wp-admin/upload.php3.26 ▲0.0334.49 ▼0.06

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

Slide to Subscribe: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,812 ▲7713.20 ▼1.014.14 ▲2.2438.99 ▼5.31
Dashboard /wp-admin2,218 ▲335.84 ▼0.17104.49 ▲5.8242.48 ▼0.86
Posts /wp-admin/edit.php2,101 ▲121.97 ▼0.0441.32 ▲1.2734.58 ▼2.01
Add New Post /wp-admin/post-new.php1,543 ▲723.00 ▼0.07577.62 ▲2.8350.63 ▼1.73
Media Library /wp-admin/upload.php1,397 ▲94.24 ▲0.06100.53 ▲7.8540.47 ▼3.40

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 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)
Even though everything seems fine, this is not an exhaustive test

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
The following issues need your attention
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/slide-to-subscribe/slide-to-subscribe.php:38

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Tags: There are too many tags (16 tag instead of maximum 10)
The official readme.txt is a good inspiration

slide-to-subscribe/slide-to-subscribe.php Passed 13 tests

The principal PHP file in "Slide to Subscribe" v. 1.1 is loaded by WordPress automatically on each request
64 characters long description:
Allow people to subscribe to your newsletters with just a slide.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected216 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP13020216

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.23
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%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
PNG images were not found in this plugin