78% wp-stripe-email-receipts

Code Review | WP Stripe Email Receipts

WordPress plugin WP Stripe Email Receipts scored78%from 54 tests.

About plugin

  • Plugin page: wp-stripe-email-r...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-3.5.2
  • WordPress version: 6.3.1
  • First release: Jun 24, 2013
  • Latest release: Jun 24, 2013
  • Number of updates: 5
  • Update frequency: every 0.2 days
  • Top authors: philip.newcomer (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /1,619 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

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

A check of server-side resources used by WP Stripe Email Receipts
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0444.58 ▲4.82
Dashboard /wp-admin3.35 ▲0.0546.16 ▼7.68
Posts /wp-admin/edit.php3.40 ▲0.0552.86 ▲5.34
Add New Post /wp-admin/post-new.php5.93 ▲0.0589.43 ▼0.00
Media Library /wp-admin/upload.php3.27 ▲0.0533.95 ▼3.14
Stripe Email Receipts /wp-admin/options-general.php?page=wp_stripe_email_receipts_settings3.2231.20

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_recent-comments
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for WP Stripe Email Receipts
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲6913.66 ▼1.091.58 ▼0.4241.05 ▼8.63
Dashboard /wp-admin2,207 ▲194.85 ▼0.9799.40 ▼7.2537.74 ▼4.95
Posts /wp-admin/edit.php2,093 ▲42.05 ▲0.0140.01 ▼1.3435.78 ▲0.76
Add New Post /wp-admin/post-new.php1,517 ▼217.56 ▼5.50658.06 ▼11.6452.10 ▼5.78
Media Library /wp-admin/upload.php1,386 ▼54.21 ▲0.0195.65 ▼1.0641.50 ▼4.92
Stripe Email Receipts /wp-admin/options-general.php?page=wp_stripe_email_receipts_settings8852.0522.6831.15

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These server-side errors were triggered
    • > GET request to /wp-admin/options-general.php?page=wp_stripe_email_receipts_settings
    • > 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=wp_stripe_email_receipts_settings
    • > 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 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just 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_action() in wp-content/plugins/wp-stripe-email-receipts/includes/admin-functions.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/wp-stripe-email-receipts/wp-stripe-email-receipts.php:34

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% 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
Attributes that require attention:
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === wp-stripe-email-receipts === )
Please take inspiration from this readme.txt

wp-stripe-email-receipts/wp-stripe-email-receipts.php Passed 13 tests

The main file in "WP Stripe Email Receipts" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
106 characters long description:
Add-on for the WP Stripe plugin: Sends an email receipt to the user after a successful Stripe transaction.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Good job! No executable or dangerous file extensions detected224 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP275107211
CSS10013

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.04
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%
Functions16
▷ Named functions16100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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
PNG images were not found in this plugin