94% woo-product-and-custom-post-type-dropdown-cf7

Code Review | Product And Custom Post type Dropdown CF7

WordPress plugin Product And Custom Post type Dropdown CF7 scored 94% from 54 tests.

About plugin

  • Plugin page: woo-product-and-c...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress version: 5.8.1
  • First release: Nov 28, 2019
  • Latest release: Aug 21, 2021
  • Number of updates: 15
  • Update frequency: every 42.2 days
  • Top authors: avdevelopers426 (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

900+ active / 3,623 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

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

This is a short check of server-side resources used by Product And Custom Post type Dropdown CF7
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.1241.53 ▲21.20
Dashboard /wp-admin3.06 ▲0.0040.50 ▲1.30
Posts /wp-admin/edit.php3.11 ▲0.0044.09 ▼1.00
Add New Post /wp-admin/post-new.php5.42 ▼0.0286.47 ▼567.19
Media Library /wp-admin/upload.php3.00 ▲0.0024.87 ▼8.86

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 65 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

Product And Custom Post type Dropdown CF7: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,696 ▲10016.35 ▲0.488.13 ▼2.8948.58 ▲3.23
Dashboard /wp-admin2,970 ▲336.07 ▼0.12134.54 ▼6.52100.40 ▼15.30
Posts /wp-admin/edit.php2,736 ▼32.69 ▼0.0063.76 ▼4.1785.11 ▼1.80
Add New Post /wp-admin/post-new.php1,615 ▼5721.49 ▲2.65271.35 ▼106.2995.52 ▼16.38
Media Library /wp-admin/upload.php1,807 ▼185.02 ▲0.02155.72 ▲25.41121.76 ▼1.72

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
Uninstall script ran successfully

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

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 fix the following items
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/woo-product-and-custom-post-type-dropdown-cf7/woo-product-and-custom-post-type-dropdown-cf7.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention: You can take inspiration from this readme.txt

woo-product-and-custom-post-type-dropdown-cf7/woo-product-and-custom-post-type-dropdown-cf7.php Passed 13 tests

This is the main PHP file of "Product And Custom Post type Dropdown CF7" version 1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
64 characters long description:
Create post List and woocommerce product list in contact form 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
Everything looks great! No dangerous files found in this plugin10,814 lines of code in 62 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript532,4516519,401
PHP515925909
CSS4570504

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.40
Average class complexity26.20
▷ Minimum class complexity6.00
▷ Maximum class complexity57.00
Average method complexity5.67
▷ Minimum method complexity1.00
▷ Maximum method complexity48.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods27
▷ Static methods518.52%
▷ Public methods27100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.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
1 PNG file occupies 0.04MB with 0.03MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/star.png39.75KB10.35KB▼ 73.95%