93% woocommerce-payment-gateway-ccbill

Code Review | WooCommerce Payment Gateway - CCBill

WordPress plugin WooCommerce Payment Gateway - CCBill scored 93% from 54 tests.

About plugin

  • Plugin page: woocommerce-payme...
  • Plugin version: 1.4.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-5.8.1
  • WordPress version: 5.8.1
  • First release: Nov 6, 2014
  • Latest release: Oct 8, 2021
  • Number of updates: 40
  • Update frequency: every 66.0 days
  • Top authors: CCBill (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

600+ active / 6,501 total downloads

Benchmarks

Plugin footprint Passed 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: ▼143.55ms] Passed 4 tests

Analyzing server-side resources used by WooCommerce Payment Gateway - CCBill
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.0032.64 ▼1.08
Dashboard /wp-admin3.06 ▲0.0144.14 ▲0.49
Posts /wp-admin/edit.php3.11 ▲0.0145.45 ▼2.62
Add New Post /wp-admin/post-new.php5.42 ▼0.0188.78 ▼567.00
Media Library /wp-admin/upload.php3.00 ▲0.0032.51 ▼3.49

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

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

WooCommerce Payment Gateway - CCBill: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,702 ▲13016.28 ▲0.249.33 ▼1.2149.57 ▲0.51
Dashboard /wp-admin2,989 ▲526.14 ▲0.12157.51 ▲1.74119.51 ▲9.69
Posts /wp-admin/edit.php2,739 ▼02.70 ▼0.0168.64 ▼4.6783.16 ▼48.69
Add New Post /wp-admin/post-new.php1,615 ▼5521.37 ▲2.01293.89 ▼135.38103.94 ▼10.34
Media Library /wp-admin/upload.php1,807 ▼05.07 ▲0.03153.88 ▼3.26116.21 ▲5.08

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The plugin uninstalled successfully, without leaving any zombie files or tables

Smoke tests 75% from 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)
The smoke test was a success, however most plugin functionality was not tested

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 fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/woocommerce-payment-gateway-ccbill/wc-gateway-ccbill.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
  • Plugin Name: Please specify the plugin name on the first line ( === woocommerce-payment-gateway-ccbill === )
  • Screenshots: A description for screenshot #1 is required in woocommerce-payment-gateway-ccbill/assets to your readme.txt
The official readme.txt might help

woocommerce-payment-gateway-ccbill/wc-gateway-ccbill.php 92% from 13 tests

The principal PHP file in "WooCommerce Payment Gateway - CCBill" v. 1.4.0 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("woocommerce-payment-gateway-ccbill.php" instead of "wc-gateway-ccbill.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
Good job! No executable or dangerous file extensions detected473 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1161163473

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity80.00
▷ Minimum class complexity80.00
▷ Maximum class complexity80.00
Average method complexity8.18
▷ Minimum method complexity1.00
▷ Maximum method complexity34.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods00.00%
▷ Public methods1090.91%
▷ Protected methods00.00%
▷ Private methods19.09%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.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