90% contact-form-query

Code Review | Contact Form Query

WordPress plugin Contact Form Query scored 90% from 54 tests.

About plugin

  • Plugin page: contact-form-query
  • Plugin version: 1.4.3
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.8
  • WordPress version: 5.8.1
  • First release: May 21, 2019
  • Latest release: Oct 13, 2021
  • Number of updates: 39
  • Update frequency: every 22.5 days
  • Top authors: scriptstown (100%)

Code review

54 tests

User reviews

1 review

Install metrics

1,000+ active / 12,357 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.23MB] [CPU: ▼168.21ms] Passed 4 tests

An overview of server-side resources used by Contact Form Query
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /2.95 ▲0.1239.63 ▼1.60
Dashboard /wp-admin3.37 ▲0.3267.78 ▲11.83
Posts /wp-admin/edit.php3.42 ▲0.3158.71 ▲8.27
Add New Post /wp-admin/post-new.php5.67 ▲0.24108.02 ▼688.88
Media Library /wp-admin/upload.php3.25 ▲0.2545.72 ▲9.39
Settings /wp-admin/admin.php?page=stcfq_settings3.2940.43
Messages /wp-admin/admin.php?page=stcfq_messages3.2839.46

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 40 new files
Database: 1 new table, no new options
New tables
wp_stcfq_queries

Browser metrics Passed 4 tests

Contact Form Query: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,853 ▲28116.05 ▲0.5014.55 ▲2.6847.50 ▼3.24
Dashboard /wp-admin3,069 ▲1385.95 ▼0.13161.88 ▼6.32116.17 ▼6.30
Posts /wp-admin/edit.php2,788 ▲522.71 ▲0.0074.04 ▼0.2094.44 ▼1.83
Add New Post /wp-admin/post-new.php1,721 ▲3818.71 ▲3.74426.76 ▼25.29118.65 ▼4.53
Media Library /wp-admin/upload.php1,856 ▲495.02 ▲0.00179.47 ▲13.59124.83 ▼0.71
Settings /wp-admin/admin.php?page=stcfq_settings2,3253.0279.54137.16
Messages /wp-admin/admin.php?page=stcfq_messages1,4252.8972.40133.63

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Zombie tables detected upon uninstall: 1 table
    • wp_stcfq_queries

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP Passed 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
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
6 plugin tags: entry, form, message, notification, email...

contact-form-query/contact-form-query.php 92% from 13 tests

The main file in "Contact Form Query" v. 1.4.3 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Description: Please keep the plugin description shorter than 140 characters (currently 148 characters long)

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
Success! There were no dangerous files found in this plugin3,807 lines of code in 37 files:
LanguageFilesBlank linesComment linesLines of code
PHP27462512,424
CSS61172584
JavaScript33111456
PO File1153194343

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity29.56
▷ Minimum class complexity1.00
▷ Maximum class complexity86.00
Average method complexity5.43
▷ Minimum method complexity1.00
▷ Maximum method complexity47.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes9
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes111.11%
Methods58
▷ Static methods5594.83%
▷ Public methods5594.83%
▷ Protected methods00.00%
▷ Private methods35.17%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.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
There were not PNG files found in your plugin