84% thank-you-page-viewer-for-woocommerce

Code Review | Thank you page viewer for Woocommerce

WordPress plugin Thank you page viewer for Woocommerce scored84%from 54 tests.

About plugin

  • Plugin page: thank-you-page-vi...
  • Plugin version: 4.6.6
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.7
  • WordPress version: 6.3.1
  • First release: Jan 8, 2019
  • Latest release: Mar 18, 2021
  • Number of updates: 34
  • Update frequency: every 27.0 days
  • Top authors: jevnet (82.35%)sperpina (20.59%)

Code review

54 tests

User reviews

3 reviews

Install metrics

800+ active /3,882 total downloads

Benchmarks

Plugin footprint 83% from 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.00MB] [CPU: ▼14.94ms] Passed 4 tests

A check of server-side resources used by Thank you page viewer for Woocommerce
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0135.97 ▼6.01
Dashboard /wp-admin3.31 ▼0.0343.08 ▼20.08
Posts /wp-admin/edit.php3.36 ▲0.0144.40 ▼6.06
Add New Post /wp-admin/post-new.php5.89 ▲0.0179.52 ▼27.60
Media Library /wp-admin/upload.php3.24 ▲0.0138.23 ▲4.14

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
db_upgraded
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

Thank you page viewer for Woocommerce: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲6013.30 ▼0.991.75 ▼0.2644.54 ▼0.90
Dashboard /wp-admin2,212 ▲245.80 ▲0.8996.61 ▼14.3840.14 ▼6.82
Posts /wp-admin/edit.php2,095 ▲62.01 ▲0.0335.27 ▼2.7230.82 ▼2.66
Add New Post /wp-admin/post-new.php1,525 ▼323.35 ▲5.05692.56 ▲44.3356.00 ▲3.03
Media Library /wp-admin/upload.php1,394 ▲64.28 ▲0.03111.21 ▲9.4146.59 ▲1.31

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
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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
Almost there! Just fix the following items
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/thank-you-page-viewer-for-woocommerce/jn-wc-thankyou-view.php

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)
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
10 plugin tags: tracking, store, pixel, woocommerce, thank you page...

thank-you-page-viewer-for-woocommerce/jn-wc-thankyou-view.php 92% from 13 tests

The primary PHP file in "Thank you page viewer for Woocommerce" version 4.6.6 is used by WordPress to initiate all plugin functionality
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("thank-you-page-viewer-for-woocommerce.php" instead of "jn-wc-thankyou-view.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
Everything looks great! No dangerous files found in this plugin139 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PO File51111113
PHP151326

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There are no PNG files in this plugin