83% remita-payment-gateway-for-easy-digital-downloads

Code Review | Remita Easy Digital Downloads Payment Plugin

WordPress plugin Remita Easy Digital Downloads Payment Plugin scored83%from 54 tests.

About plugin

  • Plugin page: remita-payment-ga...
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.3
  • WordPress version: 6.3.1
  • First release: Jun 7, 2016
  • Latest release: Aug 22, 2023
  • Number of updates: 8
  • Update frequency: every 341.2 days
  • Top authors: RemitaNet (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,590 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.05MB] [CPU: ▼6.83ms] Passed 4 tests

Analyzing server-side resources used by Remita Easy Digital Downloads Payment Plugin
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0636.97 ▼3.59
Dashboard /wp-admin3.36 ▲0.0542.93 ▼6.24
Posts /wp-admin/edit.php3.41 ▲0.0544.50 ▼1.87
Add New Post /wp-admin/post-new.php5.94 ▲0.0583.37 ▼15.61
Media Library /wp-admin/upload.php3.28 ▲0.0533.68 ▲1.19

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

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
db_upgraded
widget_recent-comments
theysaidso_admin_options
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Remita Easy Digital Downloads Payment Plugin
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲7913.23 ▼1.421.80 ▼0.1140.12 ▼3.81
Dashboard /wp-admin2,203 ▲185.84 ▲0.0395.32 ▼23.5539.60 ▼9.03
Posts /wp-admin/edit.php2,089 ▼01.99 ▼0.0236.11 ▼4.7331.74 ▼2.25
Add New Post /wp-admin/post-new.php1,542 ▲1418.14 ▼5.30599.09 ▼96.7662.41 ▲1.76
Media Library /wp-admin/upload.php1,388 ▲34.21 ▼0.0294.92 ▼17.1241.92 ▼4.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
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means 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
The following issues need your attention
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/remita-payment-gateway-for-easy-digital-downloads/edd-remita.php:22

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 83% from 29 tests

readme.txt 81% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that require attention:
  • Screenshots: Please add images for these screenshots: #4 (Selecting Remita Payment Gateway method on Woocommerce Payment Settings Page), #5 (Remita Inline Popup Page), #6 (Remita Inline OTP Page), #7 (Remita Inline Success Page)
  • Tags: There are too many tags (13 tag instead of maximum 10)
  • Requires php: Version format is invalid
The official readme.txt might help

remita-payment-gateway-for-easy-digital-downloads/edd-remita.php 85% from 13 tests

The entry point to "Remita Easy Digital Downloads Payment Plugin" version 1.2 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("remita-payment-gateway-for-easy-digital-downloads.php" instead of "edd-remita.php")
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin261 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP15325261

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.13
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%
Functions14
▷ Named functions14100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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.02MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/remita-payment-options.png24.68KB5.68KB▼ 76.98%