90% wc-cryptopay-gateway

Code Review | Cryptopay Gateway for WooCommerce

WordPress plugin Cryptopay Gateway for WooCommerce scored90%from 54 tests.

About plugin

  • Plugin page: wc-cryptopay-gateway
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.0
  • WordPress version: 6.3.1
  • First release: Jun 9, 2022
  • Latest release: Jun 9, 2022
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: aibragimovcryptopayme (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,084 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

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

An overview of server-side resources used by Cryptopay Gateway for WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.77 ▼11.85
Dashboard /wp-admin3.33 ▲0.0248.42 ▼8.37
Posts /wp-admin/edit.php3.38 ▲0.0251.07 ▼11.75
Add New Post /wp-admin/post-new.php5.91 ▲0.0286.82 ▼23.65
Media Library /wp-admin/upload.php3.25 ▲0.0238.73 ▲0.81

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Cryptopay Gateway for WooCommerce
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,796 ▲3514.41 ▼0.171.78 ▼0.0043.26 ▲6.66
Dashboard /wp-admin2,202 ▲285.62 ▲0.0494.50 ▼11.8941.74 ▼3.03
Posts /wp-admin/edit.php2,107 ▲72.03 ▲0.0339.47 ▼2.5740.00 ▼1.15
Add New Post /wp-admin/post-new.php1,533 ▲723.29 ▼0.31615.55 ▼77.1755.44 ▼2.75
Media Library /wp-admin/upload.php1,404 ▲44.31 ▲0.15102.04 ▼8.5842.64 ▼6.69

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

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
Everything seems fine, however this is by no means an exhaustive test

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 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that need to be fixed:
  • Screenshots: Add an image for screenshot #1 (Coin selection screen)
The official readme.txt is a good inspiration

wc-cryptopay-gateway/wc-cryptopay-gateway.php Passed 13 tests

The main PHP file in "Cryptopay Gateway for WooCommerce" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
95 characters long description:
Accept crypto – get fiat! Make the most of receiving, exchanging and sending crypto globally.

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 plugin316 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP34281316

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity11.50
▷ Minimum class complexity7.00
▷ Maximum class complexity16.00
Average method complexity2.17
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods18
▷ Static methods15.56%
▷ Public methods1583.33%
▷ Protected methods00.00%
▷ Private methods316.67%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants9
▷ Global constants9100.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
There were not PNG files found in your plugin