80% tkt-contact-form

Code Review | TukuToi Contact Form

WordPress plugin TukuToi Contact Form scored80%from 54 tests.

About plugin

  • Plugin page: tkt-contact-form
  • Plugin version: 2.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9.15-5.8
  • WordPress version: 6.3.1
  • First release: Sep 1, 2021
  • Latest release: Sep 9, 2021
  • Number of updates: 11
  • Update frequency: every 0.8 days
  • Top authors: bedas (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /588 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.10MB] [CPU: ▼6.28ms] Passed 4 tests

Analyzing server-side resources used by TukuToi Contact Form
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1041.17 ▼7.05
Dashboard /wp-admin3.40 ▲0.1050.41 ▼3.07
Posts /wp-admin/edit.php3.51 ▲0.1651.17 ▲0.82
Add New Post /wp-admin/post-new.php5.98 ▲0.0988.02 ▼15.80
Media Library /wp-admin/upload.php3.32 ▲0.0941.50 ▲3.62

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 17 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by TukuToi Contact Form
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.20 ▼1.221.73 ▼0.1541.72 ▼2.30
Dashboard /wp-admin2,206 ▲185.88 ▲0.86101.98 ▼7.2439.78 ▼0.61
Posts /wp-admin/edit.php2,089 ▼32.01 ▼0.0139.01 ▲3.4734.68 ▲2.16
Add New Post /wp-admin/post-new.php1,535 ▲1623.14 ▼0.11647.44 ▼89.7161.42 ▼1.18
Media Library /wp-admin/upload.php1,388 ▲34.18 ▼0.04108.05 ▼33.3750.72 ▼2.81

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • The plugin did not uninstall successfully, leaving 17 files (0.08MB) in the plugin directory
    • (new file) includes/class-tkt-contact-form-deactivator.php
    • (new file) README.txt
    • (new file) includes/class-tkt-contact-form.php
    • (new file) includes/class-tkt-contact-form-i18n.php
    • (new file) index.php
    • (new file) includes/index.php
    • (new file) includes/class-tkt-contact-form-activator.php
    • (new file) changelog.txt
    • (new file) LICENSE.txt
    • (new file) includes/class-tkt-contact-form-loader.php
    • ...
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Congratulations! This plugin passed the SRP test

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 Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: form, contact form, classicpress

tkt-contact-form/tkt-contact-form.php Passed 13 tests

The main file in "TukuToi Contact Form" v. 2.2.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
36 characters long description:
A simple Contact Form for WordPress.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin596 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PHP11243736545
JavaScript182728
CSS10423

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.45
Average class complexity13.83
▷ Minimum class complexity1.00
▷ Maximum class complexity30.00
Average method complexity2.97
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
Methods39
▷ Static methods820.51%
▷ Public methods2153.85%
▷ Protected methods00.00%
▷ Private methods1846.15%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin