89% riipay-for-woocommerce

Code Review | Riipay for WooCommerce

WordPress plugin Riipay for WooCommerce scored89%from 54 tests.

About plugin

  • Plugin page: riipay-for-woocom...
  • Plugin version: 1.0.19
  • PHP version: 7.4.16
  • WordPress compatibility: 3.2-5.9
  • WordPress version: 6.3.1
  • First release: Nov 16, 2020
  • Latest release: Feb 28, 2022
  • Number of updates: 69
  • Update frequency: every 6.8 days
  • Top authors: riipay (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /1,370 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

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

Analyzing server-side resources used by Riipay for WooCommerce
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0034.82 ▼8.92
Dashboard /wp-admin3.31 ▲0.0044.06 ▼9.88
Posts /wp-admin/edit.php3.36 ▲0.0049.28 ▲0.09
Add New Post /wp-admin/post-new.php5.89 ▲0.0094.94 ▲3.12
Media Library /wp-admin/upload.php3.23 ▲0.0036.28 ▲2.13

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
db_upgraded
theysaidso_admin_options
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Riipay for WooCommerce
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.27 ▼0.101.59 ▼0.5441.81 ▼1.19
Dashboard /wp-admin2,189 ▲95.49 ▼0.0986.34 ▼9.5237.65 ▲0.44
Posts /wp-admin/edit.php2,103 ▼01.98 ▲0.0239.77 ▲1.3240.14 ▲4.36
Add New Post /wp-admin/post-new.php1,536 ▲818.37 ▼4.81640.10 ▼34.0862.11 ▼5.32
Media Library /wp-admin/upload.php1,403 ▲34.17 ▼0.0298.78 ▼8.1341.56 ▼6.72

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
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues 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
5 plugin tags: woocommerce, malaysia, ecommerce, payment gateway, riipay

riipay-for-woocommerce/index.php 85% from 13 tests

The primary PHP file in "Riipay for WooCommerce" version 1.0.19 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Requires at least: The required version number did not match the one declared in readme.txt ("4.4" instead of "3.2")
  • Main file name: The principal plugin file should be the same as the plugin slug ("riipay-for-woocommerce.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected889 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP517271859
Markdown122025
JavaScript1015

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity46.00
▷ Minimum class complexity14.00
▷ Maximum class complexity78.00
Average method complexity3.20
▷ Minimum method complexity1.00
▷ Maximum method complexity16.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods41
▷ Static methods12.44%
▷ Public methods3892.68%
▷ Protected methods12.44%
▷ Private methods24.88%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants120.00%
▷ Class constants480.00%
▷ Public constants4100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin