84% woo-additional-checkout-fees

Code Review | WooCommerce Additional Checkout Fees

WordPress plugin WooCommerce Additional Checkout Fees scored 84% from 54 tests.

About plugin

  • Plugin page: woo-additional-ch...
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-5.7
  • WordPress version: 6.3.1
  • First release: Jun 13, 2019
  • Latest release: Mar 6, 2021
  • Number of updates: 3
  • Update frequency: every 210.7 days
  • Top authors: sajdoko (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active / 1,138 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼5.86ms] Passed 4 tests

Server-side resources used by WooCommerce Additional Checkout Fees
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0038.49 ▼8.36
Dashboard /wp-admin3.31 ▲0.0045.38 ▼5.78
Posts /wp-admin/edit.php3.36 ▲0.0048.82 ▲0.54
Add New Post /wp-admin/post-new.php5.89 ▲0.0086.72 ▼6.66
Media Library /wp-admin/upload.php3.23 ▲0.0034.19 ▼2.62

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 24 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for WooCommerce Additional Checkout Fees
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲6814.48 ▲0.121.86 ▼0.1440.90 ▼2.88
Dashboard /wp-admin2,209 ▲214.86 ▼0.0497.94 ▼16.4136.93 ▼8.60
Posts /wp-admin/edit.php2,092 ▲31.97 ▼0.0538.95 ▲1.7135.43 ▲4.67
Add New Post /wp-admin/post-new.php1,542 ▼218.58 ▲0.36592.26 ▼18.1174.84 ▲23.34
Media Library /wp-admin/upload.php1,391 ▼04.26 ▲0.03100.83 ▲4.6142.98 ▼0.30

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
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 75% from 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)
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 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
Please fix the following
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/woo-additional-checkout-fees/public/partials/woo-additional-checkout-fees-public-display.php
    • > /wp-content/plugins/woo-additional-checkout-fees/admin/partials/woo-additional-checkout-fees-admin-display.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser errors were detected

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
6 plugin tags: checkout fees, woocommerce checkout fees, fees, additional checkout fees, checkout...

woo-additional-checkout-fees/woo-additional-checkout-fees.php 92% from 13 tests

"WooCommerce Additional Checkout Fees" version 1.0.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Description: The description should be shorter than 140 characters (currently 141 characters long)

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
There were no executable files found in this plugin504 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
PHP12150536421
PO File1101240
JavaScript222735
CSS2188

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity6.71
▷ Minimum class complexity1.00
▷ Maximum class complexity25.00
Average method complexity2.14
▷ Minimum method complexity1.00
▷ Maximum method complexity11.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods35
▷ Static methods25.71%
▷ Public methods3085.71%
▷ Protected methods00.00%
▷ Private methods514.29%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG images were found in this plugin