83% contact-form-to-wp-posts

Code Review | Contact Form 7 To WordPress Post

WordPress plugin Contact Form 7 To WordPress Post scored83%from 54 tests.

About plugin

  • Plugin page: contact-form-to-w...
  • Plugin version: 0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.9.8
  • WordPress version: 6.3.1
  • First release: May 29, 2015
  • Latest release: Nov 2, 2018
  • Number of updates: 11
  • Update frequency: every 114.0 days
  • Top authors: pskli (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

80+ active /3,408 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.07MB] [CPU: ▼1.71ms] Passed 4 tests

This is a short check of server-side resources used by Contact Form 7 To WordPress Post
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0841.64 ▲2.41
Dashboard /wp-admin3.38 ▲0.0744.62 ▼6.10
Posts /wp-admin/edit.php3.49 ▲0.1444.68 ▼0.09
Add New Post /wp-admin/post-new.php5.96 ▲0.0791.56 ▲0.54
Media Library /wp-admin/upload.php3.30 ▲0.0735.83 ▼1.17
Messages /wp-admin/edit.php?post_type=cf7_form_messages3.3435.21
Add New /wp-admin/post-new.php?post_type=cf7_form_messages3.4242.86

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 9 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Contact Form 7 To WordPress Post
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,836 ▲9013.59 ▼0.701.67 ▼0.2142.85 ▼3.64
Dashboard /wp-admin2,239 ▲515.77 ▲0.8694.87 ▼19.5237.84 ▼6.39
Posts /wp-admin/edit.php2,122 ▲542.05 ▲0.0433.82 ▼2.9934.45 ▲2.51
Add New Post /wp-admin/post-new.php1,571 ▲5718.26 ▲0.68623.76 ▼69.5857.17 ▼2.99
Media Library /wp-admin/upload.php1,424 ▲364.23 ▲0.0698.75 ▼6.7344.72 ▲1.29
Messages /wp-admin/edit.php?post_type=cf7_form_messages1,0861.9530.3428.31
Add New /wp-admin/post-new.php?post_type=cf7_form_messages2,1567.55180.4464.91

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Almost there! Just fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/contact-form-to-wp-posts/cf7-to-wp.php:20

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 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
9 plugin tags: submissions, plugin, wordpress, cf7, database-form...

contact-form-to-wp-posts/cf7-to-wp.php 77% from 13 tests

Analyzing the main PHP file in "Contact Form 7 To WordPress Post" version 0.2
Please take the time to fix the following:
  • Requires at least: The required version number did not match the one declared in readme.txt ("3.9" instead of "4.0")
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("contact-form-to-wp-posts.php" instead of "cf7-to-wp.php")
  • Text Domain: The text domain name should consist of only dashes and lowercase characters

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 detected315 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP466151235
PO File1457680

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.20
Average class complexity16.00
▷ Minimum class complexity16.00
▷ Maximum class complexity16.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods15
▷ Static methods16.67%
▷ Public methods15100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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