78% post-contact-form-7-data-to-crm2

Code Review | Link Contact Form 7 to opentaps CRM2

WordPress plugin Link Contact Form 7 to opentaps CRM2 scored78%from 54 tests.

About plugin

  • Plugin page: post-contact-form...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9.3-4.1
  • WordPress version: 6.3.1
  • First release: Feb 3, 2015
  • Latest release: Feb 5, 2015
  • Number of updates: 10
  • Update frequency: every 0.6 days
  • Top authors: sichen (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /656 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

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

An overview of server-side resources used by Link Contact Form 7 to opentaps CRM2
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0239.60 ▼6.42
Dashboard /wp-admin3.32 ▲0.0250.95 ▼4.64
Posts /wp-admin/edit.php3.37 ▲0.0150.07 ▲0.77
Add New Post /wp-admin/post-new.php5.90 ▲0.0194.52 ▲2.37
Media Library /wp-admin/upload.php3.24 ▲0.0137.60 ▼0.32
Post CF7 Data To CRM2 /wp-admin/options-general.php?page=post_to_crm3.2429.16

Server storage [IO: ▲0.01MB] [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: 3 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
db_upgraded
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Link Contact Form 7 to opentaps CRM2
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.30 ▼0.061.94 ▲0.1844.36 ▼0.44
Dashboard /wp-admin2,199 ▲225.66 ▲0.0483.67 ▼14.7534.53 ▼8.31
Posts /wp-admin/edit.php2,104 ▲12.01 ▲0.0237.11 ▲0.1332.46 ▼2.85
Add New Post /wp-admin/post-new.php1,528 ▲220.98 ▼2.08641.68 ▼88.4649.38 ▼2.79
Media Library /wp-admin/upload.php1,398 ▼54.16 ▲0.0298.64 ▼3.5544.12 ▼1.79
Post CF7 Data To CRM2 /wp-admin/options-general.php?page=post_to_crm6991.516.4018.56

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=post_to_crm
    • > Error in wp-admin/includes/template.php+1801
    Uncaught ArgumentCountError: Too few arguments to function do_settings_fields(), 1 passed in wp-content/plugins/post-contact-form-7-data-to-crm2/templates/settings.php on line 22 and exactly 2 expected in wp-admin/includes/template.php:1801
    Stack trace:
    #0 wp-content/plugins/post-contact-form-7-data-to-crm2/templates/settings.php(22): do_settings_fields()
    #1 wp-content/plugins/post-contact-form-7-data-to-crm2/post-cf7-to-crm2.php(85): include('/var/www/wordpr...')
    #2 wp-includes/class-wp-hook.php(310): Post_To_CRM->plugin_settings_page()
    #3 wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters()
    #4 wp-includes/plugin.php(517): WP_Hook->do_action()
    #5 wp-admin/admin.php(259): do_action()
    #6 wp-admin/options-general.php(10): require_once('/var/www/wordpr...')
    #7 {main}
    thrown

SRP 50% from 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
Please take a closer look at the following
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/post-contact-form-7-data-to-crm2/post-cf7-to-crm2.php:173
    • > PHP Fatal error
      Uncaught Error: Call to undefined function settings_fields() in wp-content/plugins/post-contact-form-7-data-to-crm2/templates/settings.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
5 plugin tags: crm2, crm, opentaps, contact, form

post-contact-form-7-data-to-crm2/post-cf7-to-crm2.php 85% from 13 tests

The principal PHP file in "Link Contact Form 7 to opentaps CRM2" v. 1.0 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("post-contact-form-7-data-to-crm2.php" instead of "post-cf7-to-crm2.php")
  • Description: The description should be shorter than 140 characters (currently 172 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin152 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP24841152

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.24
Average class complexity10.00
▷ Minimum class complexity10.00
▷ Maximum class complexity10.00
Average method complexity2.12
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods8
▷ Static methods225.00%
▷ Public methods8100.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
There are no PNG files in this plugin