89% bransfer-crypto-payments-for-woocommerce

Code Review | Bransfer Payment Gateway

WordPress plugin Bransfer Payment Gateway scored89%from 54 tests.

About plugin

  • Plugin page: bransfer-crypto-p...
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-5.8
  • WordPress version: 6.3.1
  • First release: Sep 2, 2021
  • Latest release: Sep 6, 2021
  • Number of updates: 26
  • Update frequency: every 0.2 days
  • Top authors: bransfer (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /5,038 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼3.31ms] Passed 4 tests

An overview of server-side resources used by Bransfer Payment Gateway
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0436.67 ▲1.26
Dashboard /wp-admin3.35 ▲0.0446.51 ▼3.19
Posts /wp-admin/edit.php3.40 ▲0.0447.66 ▼1.72
Add New Post /wp-admin/post-new.php5.93 ▲0.0479.43 ▼8.11
Media Library /wp-admin/upload.php3.27 ▲0.0434.19 ▼0.20

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Bransfer Payment Gateway
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.31 ▼0.984.22 ▲2.5439.33 ▼2.97
Dashboard /wp-admin2,203 ▲185.84 ▼0.0296.97 ▼3.9938.36 ▼4.31
Posts /wp-admin/edit.php2,089 ▼02.01 ▼0.0139.37 ▼1.9335.04 ▼5.54
Add New Post /wp-admin/post-new.php1,528 ▲823.40 ▼0.02684.21 ▲32.7864.23 ▲14.12
Media Library /wp-admin/upload.php1,388 ▼04.28 ▲0.1299.24 ▲5.1641.09 ▼2.95

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • 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 everything seems fine, this is not an exhaustive test

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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that need to be fixed:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === bransfer-crypto-payments-for-woocommerce === )
The official readme.txt might help

bransfer-crypto-payments-for-woocommerce/bransfer-gateway.php 77% from 13 tests

The entry point to "Bransfer Payment Gateway" version 1.0.1 is a PHP file that has certain tags in its header comment area
Please make the necessary changes and fix the following:
  • Domain Path: The domain path points to an invalid folder, "/languages" does not exist
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("bransfer-crypto-payments-for-woocommerce.php" instead of "bransfer-gateway.php")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

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
There were no executable files found in this plugin320 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP284223320

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity16.00
▷ Minimum class complexity13.00
▷ Maximum class complexity19.00
Average method complexity2.15
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods26
▷ Static methods13.85%
▷ Public methods1246.15%
▷ Protected methods1453.85%
▷ Private methods00.00%
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

Using a strong compression for your PNG files is a great way to speed-up your plugin
2 PNG files occupy 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/logo.png3.23KB1.72KB▼ 46.68%
assets/logo.png3.23KB1.72KB▼ 46.68%