77% edd-cashapp

Code Review | Checkout with Cash App on EDD

WordPress plugin Checkout with Cash App on EDD scored 77% from 54 tests.

About plugin

  • Plugin page: edd-cashapp
  • Plugin version: 1.0
  • PHP compatiblity: 5.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.8.2
  • WordPress version: 5.9.2
  • First release: Dec 24, 2021
  • Latest release: Dec 24, 2021
  • Number of updates: 5
  • Update frequency: every 0.8 days
  • Top authors: theafricanboss (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 99 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
Install script ran successfully

Server metrics [RAM: ▼0.00MB] [CPU: ▼307.48ms] Passed 4 tests

An overview of server-side resources used by Checkout with Cash App on EDD
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /4.21 ▲0.0155.58 ▼3.85
Dashboard /wp-admin4.04 ▲0.0139.34 ▲2.37
Posts /wp-admin/edit.php4.33 ▲0.0141.26 ▼55.87
Add New Post /wp-admin/post-new.php7.57 ▼0.03100.24 ▼1,169.36
Media Library /wp-admin/upload.php3.98 ▲0.0027.34 ▼0.83

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 200 new files
Database: no new tables, 4 new options
New WordPress options
fs_active_plugins
fs_gdpr
fs_debug_mode
fs_accounts

Browser metrics Passed 4 tests

A check of browser resources used by Checkout with Cash App on EDD
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,763 ▲1915.89 ▲0.195.55 ▼0.282.05 ▼0.78
Dashboard /wp-admin2,888 ▲346.12 ▼0.02125.85 ▼15.24181.25 ▲10.66
Posts /wp-admin/edit.php2,694 ▲33.25 ▲0.0164.40 ▼3.48141.72 ▼15.28
Add New Post /wp-admin/post-new.php1,661 ▼016.47 ▼6.32442.07 ▲10.04176.23 ▲19.62
Media Library /wp-admin/upload.php1,692 ▼95.61 ▲0.07164.61 ▲21.47210.90 ▲17.07

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • This plugin does not fully uninstall, leaving 4 options in the database
    • fs_gdpr
    • fs_active_plugins
    • fs_accounts
    • fs_debug_mode

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
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
Please fix the following items
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/edd-cashapp/freemius/templates/ajax-loader.php
  • 9× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Notice
      Undefined variable: VARS in wp-content/plugins/edd-cashapp/freemius/templates/account/partials/addon.php on line 7
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/edd-cashapp/freemius/templates/account/partials/addon.php on line 6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function freemius() in wp-content/plugins/edd-cashapp/freemius/templates/partials/network-activation.php:6
    • > PHP Notice
      Undefined variable: VARS in wp-content/plugins/edd-cashapp/freemius/templates/account/partials/addon.php on line 6
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/edd-cashapp/freemius/templates/account/partials/addon.php on line 7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_die() in wp-content/plugins/edd-cashapp/languages/index.php:3
    • > PHP Notice
      Undefined variable: VARS in wp-content/plugins/edd-cashapp/freemius/templates/account/partials/addon.php on line 8
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/edd-cashapp/freemius/templates/account/partials/addon.php on line 8
    • > PHP Fatal error
      Uncaught Error: Call to a member function get_slug() on null in wp-content/plugins/edd-cashapp/freemius/templates/account/partials/addon.php:9

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 83% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Tags: Please delete some tags, you are using 17 tag instead of maximum 10
  • Screenshots: No descriptions were found for these screenshots #2, #3 in edd-cashapp/assets to your readme.txt
Please take inspiration from this readme.txt

edd-cashapp/edd-cashapp.php 77% from 13 tests

This is the main PHP file of "Checkout with Cash App on EDD" version 1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
The following require your attention:
  • Domain Path: The domain path must begin with a forward slash character ("/languages")
  • Domain Path: You should use only dashes and lowercase characters for the domain path ("languages")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 151 characters long)

Code Analysis 97% from 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 plugin31,023 lines of code in 136 files:
LanguageFilesBlank linesComment linesLines of code
PHP1197,28316,13930,803
JavaScript33459194
CSS130625
SVG1001

PHP code 50% from 2 tests

This plugin's cyclomatic complexity and code structure detailed below
The following items need your attention
  • Cyclomatic complexity of classes should be reduced to less than 1000 (currently 2,907)
Cyclomatic complexity
Average complexity per logical line of code0.63
Average class complexity90.20
▷ Minimum class complexity1.00
▷ Maximum class complexity2,907.00
Average method complexity4.65
▷ Minimum method complexity1.00
▷ Maximum method complexity86.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes45
▷ Abstract classes24.44%
▷ Concrete classes4395.56%
▷ Final classes00.00%
Methods1,132
▷ Static methods17315.28%
▷ Public methods79269.96%
▷ Protected methods151.33%
▷ Private methods32528.71%
Functions111
▷ Named functions10897.30%
▷ Anonymous functions32.70%
Constants127
▷ Global constants10280.31%
▷ Class constants2519.69%
▷ Public constants25100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
12 PNG files occupy 0.09MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
assets/images/venmo_35.png0.91KB0.79KB▼ 12.85%
assets/images/venmo-256x256.png5.29KB2.82KB▼ 46.62%
freemius/assets/img/edd-cashapp.png9.16KB5.26KB▼ 42.58%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%