10% paypal-responder

Code Review | PayPal Responder

WordPress plugin PayPal Responder scored10%from 54 tests.

About plugin

  • Plugin page: paypal-responder
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-4.7.4
  • WordPress version: 6.3.1
  • First release: Feb 16, 2013
  • Latest release: Dec 30, 2014
  • Number of updates: 17
  • Update frequency: every 90.8 days
  • Top authors: EnigmaWeb (100%)

Code review

54 tests

User reviews

15 reviews

Install metrics

100+ active /11,157 total downloads

Benchmarks

Plugin footprint 22% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
It is recommended to fix the following installer errors
  • The plugin cannot be installed
    • > Deprecated in wp-content/plugins/paypal-responder/ipn.php+41
    Function get_magic_quotes_gpc() is deprecated

Server metrics [RAM: ▲0.01MB] [CPU: ▲341.25ms] 75% from 4 tests

Server-side resources used by PayPal Responder
It is recommended to improve the following
  • Extra CPU: Try to keep extra CPU usage under 200.00ms (currently 341.25ms on /wp-admin/admin.php?page=paypal_products)
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.01364.08 ▲322.60
Dashboard /wp-admin3.32 ▲0.02442.62 ▲391.46
Posts /wp-admin/edit.php3.37 ▲0.02355.87 ▲312.37
Add New Post /wp-admin/post-new.php5.90 ▲0.01478.47 ▲388.12
Media Library /wp-admin/upload.php3.24 ▲0.01373.87 ▲341.89
Settings /wp-admin/admin.php?page=wp-paypal3.27366.24
Manage Products /wp-admin/admin.php?page=paypal_products3.25402.63

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 11 new files
Database: 2 new tables, 8 new options
New tables
wp_paypal_transactions
wp_paypal_products
New WordPress options
wp_paypal_prod_table
wp_paypal_txn_table
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for PayPal Responder
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,821 ▲7514.81 ▲0.161.54 ▼0.2636.20 ▼7.41
Dashboard /wp-admin2,225 ▲375.86 ▲0.8296.66 ▼21.9466.87 ▲17.80
Posts /wp-admin/edit.php2,137 ▲482.19 ▲0.1834.24 ▼4.5833.42 ▼2.68
Add New Post /wp-admin/post-new.php1,552 ▲1521.14 ▼2.01760.44 ▲133.6170.16 ▲20.09
Media Library /wp-admin/upload.php1,426 ▲414.17 ▼0.07110.38 ▲11.3744.79 ▲0.15
Settings /wp-admin/admin.php?page=wp-paypal1,1931.8325.7027.73
Manage Products /wp-admin/admin.php?page=paypal_products9211.7725.8725.99

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/paypal-responder/ipn.php+41
    Function get_magic_quotes_gpc() is deprecated
  • Zombie tables were found after uninstall: 2 tables
    • wp_paypal_transactions
    • wp_paypal_products
  • This plugin did not uninstall successfully, leaving 8 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • wp_paypal_prod_table
    • theysaidso_admin_options
    • widget_recent-comments
    • wp_paypal_txn_table

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Please fix the following server-side errors
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=paypal_products
    • > Notice in wp-content/plugins/paypal-responder/products/manag-products.php+8
    Undefined variable: action
    • > GET request to /wp-admin/admin.php?page=paypal_products
    • > Notice in wp-content/plugins/paypal-responder/products/process.php+46
    Undefined index: addprod
    • > GET request to /wp-admin/admin.php?page=paypal_products
    • > Notice in wp-content/plugins/paypal-responder/products/process.php+73
    Undefined variable: id
    • > GET request to /wp-admin/admin.php?page=paypal_products
    • > Notice in wp-content/plugins/paypal-responder/products/manag-products.php+35
    Undefined variable: prod
    • > GET request to /wp-admin/admin.php?page=paypal_products
    • > Notice in wp-content/plugins/paypal-responder/products/manag-products.php+35
    Undefined variable: eprod

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
  • 12× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to a member function get_row() on null in wp-content/plugins/paypal-responder/products/process.php:73
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/paypal-responder/includes/settings.php:31
    • > PHP Notice
      Undefined variable: action in wp-content/plugins/paypal-responder/products/process.php on line 14
    • > PHP Notice
      Undefined index: addprod in wp-content/plugins/paypal-responder/products/process.php on line 46
    • > PHP Notice
      Undefined variable: action in wp-content/plugins/paypal-responder/products/process.php on line 42
    • > PHP Notice
      Trying to get property 'prefix' of non-object in wp-content/plugins/paypal-responder/products/process.php on line 10
    • > PHP Notice
      Undefined variable: action in wp-content/plugins/paypal-responder/products/process.php on line 42
    • > PHP Notice
      Undefined index: addprod in wp-content/plugins/paypal-responder/products/process.php on line 46
    • > PHP Fatal error
      Uncaught Error: Call to a member function get_row() on null in wp-content/plugins/paypal-responder/products/process.php:73
    • > PHP Notice
      Trying to get property 'prefix' of non-object in wp-content/plugins/paypal-responder/products/process.php on line 10

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
8 plugin tags: email responder paypal, auto-responder, autoresponder, paypal return url, paypal responder...

paypal-responder/wp-paypal.php 85% from 13 tests

The main PHP script in "PayPal Responder" version 1.2 is automatically included on every request by WordPress
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("paypal-responder.php" instead of "wp-paypal.php")
  • Description: Please keep the plugin description shorter than 140 characters (currently 176 characters long)

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
Everything looks great! No dangerous files found in this plugin536 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP619037500
CSS12336

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.29
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%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
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
paypal-icon.png3.20KB0.54KB▼ 83.19%