94% vat-calculator-plus

Code Review | VAT Calculator Plus

WordPress plugin VAT Calculator Plus scored 94% from 54 tests.

About plugin

  • Plugin page: vat-calculator-plus
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.8.1
  • WordPress version: 5.8.1
  • First release: May 16, 2014
  • Latest release: May 16, 2014
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: VATCalculatorPlus (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active / 929 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

Server-side resources used by VAT Calculator Plus
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.0037.52 ▼0.85
Dashboard /wp-admin3.07 ▲0.0239.32 ▼11.22
Posts /wp-admin/edit.php3.12 ▲0.0242.64 ▼5.69
Add New Post /wp-admin/post-new.php5.43 ▼0.0089.68 ▼564.71
Media Library /wp-admin/upload.php3.01 ▲0.0137.19 ▲0.20
VAT Calculator Plus /wp-admin/options-general.php?page=vat-calculator-plus-admin2.9625.61

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for VAT Calculator Plus
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,707 ▲11315.83 ▲0.348.87 ▲0.4449.18 ▼2.33
Dashboard /wp-admin2,975 ▲445.89 ▼0.00142.61 ▼4.32122.37 ▲3.59
Posts /wp-admin/edit.php2,744 ▲52.70 ▲0.0070.62 ▼9.2492.69 ▲6.73
Add New Post /wp-admin/post-new.php1,503 ▼18018.62 ▼0.03384.72 ▼2.67112.88 ▼3.34
Media Library /wp-admin/upload.php1,815 ▲85.03 ▼0.01154.03 ▼3.87121.23 ▼4.67
VAT Calculator Plus /wp-admin/options-general.php?page=vat-calculator-plus-admin1,2022.3767.25114.26

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The plugin uninstalled completely, with no zombie files or tables

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Almost there, just fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=vat-calculator-plus-admin
    • > User deprecated in wp-includes/functions.php+5221
    screen_icon is deprecated since version 3.8.0 with no alternative available.
    • > GET request to /wp-admin/options-general.php?page=vat-calculator-plus-admin
    • > User deprecated in wp-includes/functions.php+5221
    get_screen_icon is deprecated since version 3.8.0 with no alternative available.

SRP Passed 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: calculator, business, shortcode, vat calculator, accounting...

vat-calculator-plus/vat-calculator-plus.php 85% from 13 tests

The main file in "VAT Calculator Plus" v. 1.0.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 305 characters long)
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug

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
Everything looks great! No dangerous files found in this plugin181 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP23141157
JavaScript18424

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity8.00
▷ Minimum class complexity8.00
▷ Maximum class complexity8.00
Average method complexity1.64
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods11
▷ Static methods19.09%
▷ Public methods1090.91%
▷ Protected methods00.00%
▷ Private methods19.09%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin