83% instant-payment-receipts-in-woocommerce-for-bacs

Code Review | Instant Payment Receipts in WooCommerce for BACS

WordPress plugin Instant Payment Receipts in WooCommerce for BACS scored83%from 54 tests.

About plugin

  • Plugin page: instant-payment-r...
  • Plugin version: 1.1.0
  • PHP compatiblity: 5.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-5.2
  • WordPress version: 6.3.1
  • First release: Aug 14, 2019
  • Latest release: Aug 17, 2019
  • Number of updates: 3
  • Update frequency: every 3.0 days
  • Top authors: artdevstudios1 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /898 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼11.03ms] Passed 4 tests

This is a short check of server-side resources used by Instant Payment Receipts in WooCommerce for BACS
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0345.02 ▲5.39
Dashboard /wp-admin3.33 ▼0.0252.00 ▼16.17
Posts /wp-admin/edit.php3.38 ▲0.0251.44 ▼14.94
Add New Post /wp-admin/post-new.php5.91 ▲0.0296.58 ▼9.78
Media Library /wp-admin/upload.php3.25 ▲0.0236.15 ▼3.21

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Instant Payment Receipts in WooCommerce for BACS
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,886 ▲12513.38 ▼0.888.61 ▲6.9642.10 ▼2.97
Dashboard /wp-admin2,211 ▲345.64 ▼0.0585.47 ▼8.4436.48 ▼10.29
Posts /wp-admin/edit.php2,113 ▲132.02 ▲0.0239.84 ▲1.7734.35 ▼5.15
Add New Post /wp-admin/post-new.php1,534 ▲623.21 ▲0.11637.17 ▼37.1152.43 ▲1.46
Media Library /wp-admin/upload.php1,416 ▲164.24 ▼0.01101.34 ▼15.9542.69 ▼6.88

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
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check 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
Please take a closer look at the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/instant-payment-receipts-in-woocommerce-for-bacs/instant-woo-bacs-payment-receipt.php:27

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that need to be fixed:
  • Screenshots: Screenshot #1 (backend Layout) image not found
The official readme.txt is a good inspiration

instant-payment-receipts-in-woocommerce-for-bacs/instant-woo-bacs-payment-receipt.php 85% from 13 tests

This is the main PHP file of "Instant Payment Receipts in WooCommerce for BACS" version 1.1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("instant-payment-receipts-in-woocommerce-for-bacs.php" instead of "instant-woo-bacs-payment-receipt.php")
  • Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin94 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP1413463
JavaScript16031

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.05MB with 0.05MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
(invalid) screenshot.png47.10KB0.00KB▼ 100.00%