100% payment-options-per-product

Code Review | Payment Options per Product

WordPress plugin Payment Options per Product scored 100% from 53 tests.

About plugin

  • Plugin page: payment-options-p...
  • Plugin version: 1.0.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.7-4.5.3
  • WordPress version: 5.8.1
  • First release: May 29, 2017
  • Latest release: May 29, 2017
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: PayIBAN (100%)

Code review

53 tests

User reviews

1 review

Install metrics

10+ active / 443 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

A check of server-side resources used by Payment Options per Product
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.1331.46 ▲9.30
Dashboard /wp-admin3.07 ▲0.0249.65 ▲6.69
Posts /wp-admin/edit.php3.12 ▲0.0243.59 ▼1.20
Add New Post /wp-admin/post-new.php5.44 ▲0.0190.63 ▼1,094.30
Media Library /wp-admin/upload.php3.02 ▲0.0136.26 ▼2.01

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 3 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Payment Options per Product
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,673 ▲6715.77 ▼0.108.26 ▼0.2250.31 ▼2.99
Dashboard /wp-admin2,930 ▲805.90 ▲0.10136.69 ▼4.38112.47 ▲2.37
Posts /wp-admin/edit.php2,706 ▼02.69 ▲0.0269.41 ▲2.6385.50 ▼4.65
Add New Post /wp-admin/post-new.php1,481 ▼17218.52 ▼0.17360.96 ▼8.64108.03 ▼4.10
Media Library /wp-admin/upload.php1,775 ▲35.01 ▲0.03168.25 ▲19.25113.17 ▼4.50

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
Uninstaller ran successfully

Smoke tests Passed 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 Passed 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
Looking good! No server-side errors or output 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, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: incasso, ideal, payment gateway, woocommerce, subscriptions...

payment-options-per-product/payment-options-per-product.php 92% from 13 tests

The main PHP script in "Payment Options per Product" version 1.0.3 is automatically included on every request by WordPress
You should first fix the following items:
  • Requires at least: Required version does not match the one declared in readme.txt ("3.7.0" instead of "3.7")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Success! There were no dangerous files found in this plugin95 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1162695

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.95
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%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 1 test

Image compression Passed 1 test

PNG files should be compressed to save space and minimize bandwidth usage
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/icon.png3.46KB2.18KB▼ 37.00%