84% checkout-paypal-woo

Code Review | PayPal Payments For WooCommerce by Checkout Plugins

WordPress plugin PayPal Payments For WooCommerce by Checkout Plugins scored84%from 54 tests.

About plugin

  • Plugin page: checkout-paypal-woo
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.4-6.3
  • WordPress version: 6.3.1
  • First release: Mar 10, 2023
  • Latest release: Aug 25, 2023
  • Number of updates: 7
  • Update frequency: every 24.3 days
  • Top authors: brainstormworg (100%)

Code review

54 tests

User reviews

1 review

Install metrics

2,000+ active /11,549 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼6.74ms] Passed 4 tests

This is a short check of server-side resources used by PayPal Payments For WooCommerce by Checkout Plugins
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0240.60 ▼0.44
Dashboard /wp-admin3.31 ▲0.0149.04 ▼2.78
Posts /wp-admin/edit.php3.37 ▲0.0150.77 ▲0.05
Add New Post /wp-admin/post-new.php5.90 ▲0.0182.93 ▼23.79
Media Library /wp-admin/upload.php3.24 ▲0.0137.82 ▲1.55

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 29 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
cppw_start_onboarding
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

PayPal Payments For WooCommerce by Checkout Plugins: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲7313.25 ▼1.134.86 ▲3.0543.89 ▲4.40
Dashboard /wp-admin2,225 ▲374.86 ▼0.95110.98 ▲2.3940.36 ▼3.41
Posts /wp-admin/edit.php2,107 ▲182.07 ▲0.0340.50 ▲1.4434.00 ▼1.31
Add New Post /wp-admin/post-new.php1,547 ▲1123.45 ▲0.02679.04 ▲12.5960.67 ▼1.08
Media Library /wp-admin/upload.php1,410 ▲224.15 ▼0.02110.32 ▼4.4947.78 ▼2.57

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • cppw_start_onboarding
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 12× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'WC_Payment_Gateway' not found in wp-content/plugins/checkout-paypal-woo/gateway/abstract-payment-gateway.php:24
    • > PHP Fatal error
      Trait 'CPPW\\Gateway\\Paypal\\Subscription\\Subscription_Helper' not found in wp-content/plugins/checkout-paypal-woo/gateway/paypal/subscription/subscriptions.php on line 19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/checkout-paypal-woo/checkout-paypal-woo.php:19
    • > PHP Fatal error
      Uncaught Error: Call to undefined function CPPW\\register_activation_hook() in wp-content/plugins/checkout-paypal-woo/autoloader.php:88
    • > PHP Fatal error
      Trait 'CPPW\\Inc\\Traits\\Get_Instance' not found in wp-content/plugins/checkout-paypal-woo/admin/admin-controller.php on line 24
    • > PHP Fatal error
      Trait 'CPPW\\Inc\\Traits\\Get_Instance' not found in wp-content/plugins/checkout-paypal-woo/admin/order-meta.php on line 20
    • > PHP Fatal error
      Uncaught Error: Class 'CPPW\\Gateway\\Abstract_Payment_Gateway' not found in wp-content/plugins/checkout-paypal-woo/gateway/paypal/webhook/listener.php:24
    • > PHP Fatal error
      Trait 'CPPW\\Gateway\\Paypal\\Api\\Client' not found in wp-content/plugins/checkout-paypal-woo/gateway/paypal/api/payments.php on line 16
    • > PHP Fatal error
      Trait 'CPPW\\Inc\\Traits\\Get_Instance' not found in wp-content/plugins/checkout-paypal-woo/admin/ajax-calls.php on line 24
    • > PHP Fatal error
      Uncaught Error: Class 'CPPW\\Gateway\\Abstract_Payment_Gateway' not found in wp-content/plugins/checkout-paypal-woo/gateway/paypal/paypal-payments.php:26

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

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
3 plugin tags: paypal payment gateway, paypal payments woocommerce, venmo

checkout-paypal-woo/checkout-paypal-woo.php 92% from 13 tests

The main PHP script in "PayPal Payments For WooCommerce by Checkout Plugins" version 1.0.0 is automatically included on every request by WordPress
You should first fix the following items:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 180 characters long)

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
No dangerous file extensions were detected3,145 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
PHP214411,5632,326
JavaScript21217400
CSS2533249
SVG100170

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity20.80
▷ Minimum class complexity1.00
▷ Maximum class complexity52.00
Average method complexity3.48
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces9
Interfaces0
Traits4
Classes16
▷ Abstract classes16.25%
▷ Concrete classes1593.75%
▷ Final classes00.00%
Methods160
▷ Static methods4528.12%
▷ Public methods15093.75%
▷ Protected methods00.00%
▷ Private methods106.25%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants15
▷ Global constants15100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/icon/cppw_paypal.png2.05KB0.83KB▼ 59.65%