83% free-vehicle-data-uk

Code Review | Free Vehicle Data UK

WordPress plugin Free Vehicle Data UK scored83%from 54 tests.

About plugin

  • Plugin page: free-vehicle-data-uk
  • Plugin version: 1.38
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Jan 27, 2021
  • Latest release: Nov 8, 2023
  • Number of updates: 31
  • Update frequency: every 32.7 days
  • Top authors: rapidcarcheck (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

200+ active /5,367 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

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

An overview of server-side resources used by Free Vehicle Data UK
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0239.88 ▲1.00
Dashboard /wp-admin3.32 ▲0.0246.41 ▼0.20
Posts /wp-admin/edit.php3.37 ▲0.0246.22 ▼9.26
Add New Post /wp-admin/post-new.php5.90 ▲0.0190.71 ▼5.42
Media Library /wp-admin/upload.php3.24 ▲0.0131.03 ▼1.76

Server storage [IO: ▲0.68MB] [DB: ▲0.07MB] Passed 3 tests

Filesystem and database footprint
No storage issues were detected
Filesystem: 35 new files
Database: no new tables, 9 new options
New WordPress options
db_upgraded
FVDUKDisableEndPoint
FVDUKCreditUs
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
FVDUKCreditLink
can_compress_scripts

Browser metrics Passed 4 tests

Free Vehicle Data UK: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,810 ▲4814.37 ▼0.341.79 ▲0.0645.50 ▲0.24
Dashboard /wp-admin2,213 ▲335.68 ▲0.0484.49 ▼1.5538.18 ▲2.49
Posts /wp-admin/edit.php2,118 ▲182.00 ▼0.0147.74 ▲9.1638.37 ▲2.92
Add New Post /wp-admin/post-new.php1,540 ▲523.17 ▲4.73657.85 ▲3.4550.97 ▼11.98
Media Library /wp-admin/upload.php1,418 ▲184.24 ▲0.05100.87 ▲3.8540.41 ▼0.05

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • This plugin did not uninstall successfully, leaving 9 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • FVDUKCreditLink
    • FVDUKCreditUs
    • FVDUKDisableEndPoint
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget

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)
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 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
Please fix the following
  • 4× PHP files output text when accessed directly:
    • > /wp-content/plugins/free-vehicle-data-uk/templates/2-col-layout.php
    • > /wp-content/plugins/free-vehicle-data-uk/templates/2-col-layout-alt-img.php
    • > /wp-content/plugins/free-vehicle-data-uk/templates/1-col-layout.php
    • > /wp-content/plugins/free-vehicle-data-uk/templates/2-col-layout-alt.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed: Please take inspiration from this readme.txt

free-vehicle-data-uk/fvd.php 85% from 13 tests

"Free Vehicle Data UK" version 1.38's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("free-vehicle-data-uk.php" instead of "fvd.php")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

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
No dangerous file extensions were detected1,684 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP93912281,333
CSS2310351

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity29.50
▷ Minimum class complexity1.00
▷ Maximum class complexity86.00
Average method complexity8.60
▷ Minimum method complexity1.00
▷ Maximum method complexity61.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes125.00%
Methods15
▷ Static methods213.33%
▷ Public methods15100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
19 compressed PNG files occupy 0.27MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/taxband/L.png21.35KB22.31KB0.00%
assets/taxband/C.png21.02KB21.89KB0.00%
assets/taxband/F.png19.55KB20.43KB0.00%
assets/taxband/I.png20.20KB21.07KB0.00%
assets/taxband/G.png20.72KB21.57KB0.00%