58% addon-stripe-with-contact-form-7

Code Review | Addon Stripe with contact form 7

WordPress plugin Addon Stripe with contact form 7 scored58%from 54 tests.

About plugin

  • Plugin page: addon-stripe-with...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 5.5-6.3.1
  • WordPress version: 6.3.1
  • First release: Sep 10, 2022
  • Latest release: Sep 26, 2023
  • Number of updates: 4
  • Update frequency: every 95.3 days
  • Top authors: silverplugins217 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /211 total downloads


Plugin footprint 65% 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: ▲2.57MB] [CPU: ▲6.86ms] Passed 4 tests

This is a short check of server-side resources used by Addon Stripe with contact form 7
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /6.05 ▲2.5860.02 ▲11.84
Dashboard /wp-admin5.88 ▲2.5765.70 ▲13.78
Posts /wp-admin/edit.php5.93 ▲2.5771.73 ▲16.06
Add New Post /wp-admin/post-new.php8.48 ▲2.59101.24 ▼11.65
Media Library /wp-admin/upload.php5.80 ▲2.5752.04 ▲13.45
Stripe Entries /wp-admin/admin.php?page=cfywpay_stripe_entries5.7845.82

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 242 new files
Database: 1 new table, 6 new options
New tables
New WordPress options

Browser metrics Passed 4 tests

An overview of browser requirements for Addon Stripe with contact form 7
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,982 ▲22116.73 ▲2.48169.91 ▲167.9146.66 ▲7.46
Dashboard /wp-admin2,237 ▲374.82 ▼1.06116.14 ▲9.1042.21 ▼1.98
Posts /wp-admin/edit.php2,120 ▲172.05 ▼0.0038.71 ▼3.1937.18 ▲0.61
Add New Post /wp-admin/post-new.php1,551 ▲618.47 ▼4.94651.24 ▼5.5556.72 ▼3.51
Media Library /wp-admin/upload.php1,419 ▲194.21 ▼0.02101.30 ▼2.4039.71 ▼7.75
Stripe Entries /wp-admin/admin.php?page=cfywpay_stripe_entries8881.6826.7624.41

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • The plugin did not uninstall successfully, leaving 1 table in the database
    • wp_cf7spay_forms
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% 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
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/build.php
    • > /wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/update_certs.php
  • 189× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/lib/InvoiceItem.php:38
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/lib/ApplicationFee.php:21
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/lib/Recipient.php:36
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/lib/RecipientTransfer.php:33
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/lib/Transfer.php:37
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\Exception\\ApiErrorException' not found in wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/lib/Exception/ApiConnectionException.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\Service\\AbstractService' not found in wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/lib/Service/OAuthService.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\Service\\AbstractService' not found in wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/lib/Service/PayoutService.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/addon-stripe-with-contact-form-7/main/resources/cfyspay-language.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'Stripe\\ApiResource' not found in wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/lib/CreditNote.php:37

User-side errors Passed 1 test

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


Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that need to be fixed: You can look at the official readme.txt

addon-stripe-with-contact-form-7/stripe-with-contact-form-7.php 92% from 13 tests

This is the main PHP file of "Addon Stripe with contact form 7" version 1.0, 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: The principal plugin file should be the same as the plugin slug ("addon-stripe-with-contact-form-7.php" instead of "stripe-with-contact-form-7.php")

Code Analysis 5% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Almost there! Just fix the following issues
  • Do not include executable or dangerous files in your plugin
    • .crt - Security Certificate in Firefox, IE, Chrome, Safari
      • wp-content/plugins/addon-stripe-with-contact-form-7/includes/stripe_library/data/ca-certificates.crt
9,797 lines of code in 229 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity3.11
▷ Minimum class complexity1.00
▷ Maximum class complexity60.00
Average method complexity1.64
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
▷ Abstract classes105.08%
▷ Concrete classes18794.92%
▷ Final classes00.00%
▷ Static methods15422.81%
▷ Public methods60789.93%
▷ Protected methods294.30%
▷ Private methods395.78%
▷ Named functions2482.76%
▷ Anonymous functions517.24%
▷ Global constants50.75%
▷ Class constants66099.25%
▷ Public constants660100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
4 PNG files occupy 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/image/minus_1.png0.91KB0.67KB▼ 27.06%
includes/image/plus-circular-button_1.png0.62KB0.38KB▼ 39.27%
includes/image/minus.png0.61KB0.37KB▼ 40.19%
includes/image/plus-circular-button.png0.94KB0.69KB▼ 26.59%