84% geidea-online-payments

Code Review | Geidea Online Payments for WooCommerce

WordPress plugin Geidea Online Payments for WooCommerce scored84%from 54 tests.

About plugin

  • Plugin page: geidea-online-pay...
  • Plugin version: 2.0.4
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0.2-6.2
  • WordPress version: 6.3.1
  • First release: Jun 16, 2021
  • Latest release: Jun 21, 2023
  • Number of updates: 67
  • Update frequency: every 11.7 days
  • Top authors: geideapg123 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

70+ active /2,631 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 successfully, without throwing any errors or notices

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

Analyzing server-side resources used by Geidea Online Payments for WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0045.18 ▲2.73
Dashboard /wp-admin3.31 ▲0.0048.52 ▲1.27
Posts /wp-admin/edit.php3.36 ▲0.0050.00 ▼0.46
Add New Post /wp-admin/post-new.php5.89 ▲0.0085.85 ▼21.81
Media Library /wp-admin/upload.php3.23 ▲0.0040.26 ▲2.75

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 26 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

Geidea Online Payments for WooCommerce: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.40 ▲0.101.88 ▼0.5643.65 ▼2.85
Dashboard /wp-admin2,195 ▲155.68 ▼0.0190.81 ▼1.5741.40 ▼2.22
Posts /wp-admin/edit.php2,100 ▼02.03 ▲0.0339.16 ▲0.5535.34 ▼1.40
Add New Post /wp-admin/post-new.php1,526 ▼1917.59 ▼5.69657.10 ▼28.7952.97 ▼9.84
Media Library /wp-admin/upload.php1,397 ▼04.20 ▼0.0796.79 ▼17.7944.36 ▼2.18

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/geidea-online-payments/includes/GITable.php on line 6
    • > PHP Warning
      require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/geidea-online-payments/includes/GITable.php on line 6
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/geidea-online-payments/includes/GITable.php on line 6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_uninstall_hook() in wp-content/plugins/geidea-online-payments/uninstall.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
8 plugin tags: payment request, payment, payment for woocommerce, geidea, payment for wordpress...

geidea-online-payments/wc-geidea.php 92% from 13 tests

Analyzing the main PHP file in "Geidea Online Payments for WooCommerce" version 2.0.4
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("geidea-online-payments.php" instead of "wc-geidea.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
There were no executable files found in this plugin2,001 lines of code in 25 files:
LanguageFilesBlank linesComment linesLines of code
PHP181871001,911
JavaScript29069
SVG40012
CSS1109

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity13.15
▷ Minimum class complexity1.00
▷ Maximum class complexity34.00
Average method complexity4.92
▷ Minimum method complexity1.00
▷ Maximum method complexity23.00
Code structure
Namespaces2
Interfaces0
Traits11
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods41
▷ Static methods49.76%
▷ Public methods3687.80%
▷ Protected methods00.00%
▷ Private methods512.20%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants99
▷ Global constants33.03%
▷ Class constants9696.97%
▷ Public constants96100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin