94% accept-bitcoin-payin-local-by-align-commerce-for-wp-ecommerce

Code Review | WP-eCommerce - Accept Bitcoin and Payin Local Gateway by Align Commerce

WordPress plugin WP-eCommerce - Accept Bitcoin and Payin Local Gateway by Align Commerce scored 94% from 54 tests.

About plugin

  • Plugin page: accept-bitcoin-pa...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.4
  • WordPress version: 5.9.2
  • First release: Oct 16, 2014
  • Latest release: Nov 26, 2014
  • Number of updates: 8
  • Update frequency: every 5.3 days
  • Top authors: aligncommerce (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 918 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

Server metrics [RAM: ▼0.02MB] [CPU: ▼320.28ms] Passed 4 tests

A check of server-side resources used by WP-eCommerce - Accept Bitcoin and Payin Local Gateway by Align Commerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0159.71 ▲4.81
Dashboard /wp-admin3.41 ▲0.0035.52 ▼13.33
Posts /wp-admin/edit.php3.64 ▲0.0039.28 ▼8.07
Add New Post /wp-admin/post-new.php6.88 ▼0.09106.80 ▼1,256.31
Media Library /wp-admin/upload.php3.29 ▲0.0027.74 ▼3.41

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 6 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

WP-eCommerce - Accept Bitcoin and Payin Local Gateway by Align Commerce: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,763 ▲915.90 ▲0.156.37 ▼0.002.56 ▲0.01
Dashboard /wp-admin2,888 ▲346.15 ▲0.00117.10 ▼18.61215.29 ▲55.54
Posts /wp-admin/edit.php2,691 ▲33.23 ▼0.0162.73 ▼0.81148.20 ▼3.06
Add New Post /wp-admin/post-new.php1,690 ▼2121.00 ▲0.36434.53 ▼7.07197.49 ▼27.41
Media Library /wp-admin/upload.php1,694 ▼75.47 ▼0.03161.85 ▲20.30204.88 ▼35.53

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
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 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 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
Almost there! Just fix the following items
  • 5× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_uninstall_hook() in wp-content/plugins/accept-bitcoin-payin-local-by-align-commerce-for-wp-ecommerce/alligncommerce_payment.php:20
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/accept-bitcoin-payin-local-by-align-commerce-for-wp-ecommerce/alligncommerce_payment.php on line 18
    • > PHP Warning
      include_once(ABSPATHwp-admin/includes/plugin.php): failed to open stream: No such file or directory in wp-content/plugins/accept-bitcoin-payin-local-by-align-commerce-for-wp-ecommerce/alligncommerce_payment.php on line 18
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/accept-bitcoin-payin-local-by-align-commerce-for-wp-ecommerce/alligncommerce_bank_transfer_pay.php:7
    • > PHP Warning
      include_once(): Failed opening 'ABSPATHwp-admin/includes/plugin.php' for inclusion (include_path='.:/usr/share/php') in wp-content/plugins/accept-bitcoin-payin-local-by-align-commerce-for-wp-ecommerce/alligncommerce_payment.php on line 18

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
6 plugin tags: woocommerce, gateway, bitcoin, euro, web payments...

accept-bitcoin-payin-local-by-align-commerce-for-wp-ecommerce/alligncommerce_payment.php 92% from 13 tests

"WP-eCommerce - Accept Bitcoin and Payin Local Gateway by Align Commerce" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("accept-bitcoin-payin-local-by-align-commerce-for-wp-ecommerce.php" instead of "alligncommerce_payment.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin882 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2137188882

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity5.00
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods3
▷ Static methods00.00%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
3 PNG files occupy 0.24MB with 0.14MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png122.81KB42.28KB▼ 65.57%
screenshot-1.png41.44KB23.29KB▼ 43.80%
screenshot-3.png84.76KB35.14KB▼ 58.54%