84% contact-form-7-getresponse-extension

Code Review | Contact Form 7 GetResponse Extension

WordPress plugin Contact Form 7 GetResponse Extension scored84%from 54 tests.

About plugin

  • Plugin page: contact-form-7-ge...
  • Plugin version: 1.0.7
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9-6.2
  • WordPress version: 6.3.1
  • First release: Jul 24, 2015
  • Latest release: Jul 5, 2023
  • Number of updates: 29
  • Update frequency: every 100.1 days
  • Top authors: WEN Solutions (86.21%)wptravel (17.24%)

Code review

54 tests

User reviews

7 reviews

Install metrics

1,000+ active /18,339 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▼0.01MB] [CPU: ▼9.35ms] Passed 4 tests

Analyzing server-side resources used by Contact Form 7 GetResponse Extension
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0045.14 ▼0.44
Dashboard /wp-admin3.31 ▼0.0448.62 ▼20.40
Posts /wp-admin/edit.php3.36 ▲0.0047.58 ▼3.25
Add New Post /wp-admin/post-new.php5.89 ▲0.0084.86 ▼13.29
Media Library /wp-admin/upload.php3.23 ▲0.0044.09 ▲7.06

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Contact Form 7 GetResponse Extension
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.29 ▼0.091.68 ▼0.1548.15 ▲4.42
Dashboard /wp-admin2,192 ▲125.58 ▼0.0685.13 ▼16.6837.46 ▼5.51
Posts /wp-admin/edit.php2,103 ▲32.03 ▼0.0235.00 ▼3.3030.50 ▼6.41
Add New Post /wp-admin/post-new.php1,531 ▼1322.99 ▼0.31625.25 ▼50.5450.75 ▲0.51
Media Library /wp-admin/upload.php1,397 ▼64.22 ▼0.17100.31 ▼3.7650.71 ▲8.47

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/contact-form-7-getresponse-extension/admin/partials/cf7-gr-ext-admin-display.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
10 plugin tags: contact form, newsletter, email, getresponse, form...

contact-form-7-getresponse-extension/cf7-gs-ext.php 85% from 13 tests

The primary PHP file in "Contact Form 7 GetResponse Extension" version 1.0.7 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("contact-form-7-getresponse-extension.php" instead of "cf7-gs-ext.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected1,562 lines of code in 27 files:
LanguageFilesBlank linesComment linesLines of code
PHP223698161,188
JavaScript14410134
Markdown110085
CSS115478
JSON20077

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity10.58
▷ Minimum class complexity1.00
▷ Maximum class complexity39.00
Average method complexity2.24
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes12
▷ Abstract classes00.00%
▷ Concrete classes12100.00%
▷ Final classes00.00%
Methods94
▷ Static methods66.38%
▷ Public methods8388.30%
▷ Protected methods00.00%
▷ Private methods1111.70%
Functions7
▷ Named functions685.71%
▷ Anonymous functions114.29%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG images were found in this plugin