90% ikhokha-payment-gateway

Code Review | Online Payments with iK Pay Gateway

WordPress plugin Online Payments with iK Pay Gateway scored 90% from 54 tests.

About plugin

  • Plugin page: ikhokha-payment-g...
  • Plugin version: 1.1.12
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6-6.2
  • WordPress version: 6.3.1
  • First release: Nov 25, 2021
  • Latest release: Apr 13, 2023
  • Number of updates: 33
  • Update frequency: every 15.3 days
  • Top authors: ikhokhasupport (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

700+ active / 4,838 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
Installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼2.59ms] Passed 4 tests

Analyzing server-side resources used by Online Payments with iK Pay Gateway
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.53 ▲0.0745.92 ▲2.02
Dashboard /wp-admin3.38 ▲0.0752.12 ▲2.99
Posts /wp-admin/edit.php3.49 ▲0.1347.67 ▼0.71
Add New Post /wp-admin/post-new.php5.98 ▲0.0995.12 ▼3.74
Media Library /wp-admin/upload.php3.30 ▲0.0737.98 ▼7.92

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Online Payments with iK Pay Gateway
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,813 ▲5613.23 ▼1.324.19 ▲2.0140.97 ▼1.55
Dashboard /wp-admin2,219 ▲314.88 ▼0.01114.46 ▲9.8547.22 ▲1.33
Posts /wp-admin/edit.php2,102 ▲132.03 ▲0.0135.56 ▼4.6135.23 ▼1.16
Add New Post /wp-admin/post-new.php1,530 ▲1623.32 ▲5.81658.17 ▲18.9152.21 ▲0.62
Media Library /wp-admin/upload.php1,395 ▲104.22 ▲0.0599.22 ▼3.9943.81 ▲0.85

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

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 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
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 just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
3 plugin tags: woocommerce, ikhokha, payment gateway

ikhokha-payment-gateway/index.php 92% from 13 tests

The main PHP script in "Online Payments with iK Pay Gateway" version 1.1.12 is automatically included on every request by WordPress
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("ikhokha-payment-gateway.php" instead of "index.php")

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
There were no executable files found in this plugin478 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP116895376
Markdown152099
JavaScript1003

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity48.00
▷ Minimum class complexity48.00
▷ Maximum class complexity48.00
Average method complexity4.62
▷ Minimum method complexity1.00
▷ Maximum method complexity21.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods13
▷ Static methods00.00%
▷ Public methods13100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions8
▷ Named functions675.00%
▷ Anonymous functions225.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
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/images/wc_ikhokha.png4.50KB2.42KB▼ 46.26%