67% cf7-reply-manager

Code Review | CF7 Reply Manager

WordPress plugin CF7 Reply Manager scored67%from 54 tests.

About plugin

  • Plugin page: cf7-reply-manager
  • Plugin version: 1.2.3
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-6.1
  • WordPress version: 6.3.1
  • First release: May 9, 2019
  • Latest release: Feb 10, 2023
  • Number of updates: 10
  • Update frequency: every 137.3 days
  • Top authors: jadascript (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /777 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▼1.96MB] [CPU: ▼52.96ms] Passed 4 tests

Analyzing server-side resources used by CF7 Reply Manager
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.03 ▼1.444.60 ▼31.04
Dashboard /wp-admin2.05 ▼1.265.21 ▼44.33
Posts /wp-admin/edit.php2.05 ▼1.315.35 ▼40.31
Add New Post /wp-admin/post-new.php2.05 ▼3.845.87 ▼96.15
Media Library /wp-admin/upload.php2.05 ▼1.185.82 ▼29.36
Settings /wp-admin/admin.php?page=cf7_reply_manager-settings2.055.63
CF7 Reply Manager /wp-admin/admin.php?page=cf7_reply_manager2.057.20

Server storage [IO: ▲0.21MB] [DB: ▲0.00MB] 67% from 3 tests

Input-output and database impact of this plugin
Just a few items left to fix
  • You have illegally modified 1 file (0.00KB) outside of "wp-content/plugins/cf7-reply-manager/" and "wp-content/uploads/"
    • (new file) wp-content/cf7-rm-uploads/.empty
Filesystem: 17 new files
Database: 3 new tables, 6 new options
New tables
wp_cf7rm_vdata_entry
wp_cf7rm_replies
wp_cf7rm_vdata
New WordPress options
theysaidso_admin_options
widget_recent-comments
db_upgraded
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for CF7 Reply Manager
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,833 ▲4714.42 ▲0.072.04 ▲0.2935.98 ▼5.87
Dashboard /wp-admin2,231 ▲515.62 ▲0.0081.62 ▼2.1139.92 ▲0.13
Posts /wp-admin/edit.php2,133 ▲332.02 ▲0.0035.00 ▼0.3634.05 ▼1.64
Add New Post /wp-admin/post-new.php1,558 ▲1923.20 ▲0.15673.14 ▼20.0561.22 ▲4.71
Media Library /wp-admin/upload.php1,436 ▲394.22 ▼0.0196.42 ▼3.7445.95 ▲3.87
Settings /wp-admin/admin.php?page=cf7_reply_manager-settings1,9937.99156.9859.51
CF7 Reply Manager /wp-admin/admin.php?page=cf7_reply_manager1,0772.6654.5438.14

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • This plugin cannot be uninstalled
    • > User notice in wp-includes/functions.php+5905
    Function wp_register_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the cf7_rm_style handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Please fix the following server-side errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager
    • > User notice in wp-includes/functions.php+5905
    Function wp_register_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the cf7_rm_style handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the cf7_rm_style handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager
    • > User notice in wp-includes/functions.php+5905
    Function wp_register_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the cf7_rm_script handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager
    • > User notice in wp-includes/functions.php+5905
    Function wp_enqueue_script was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or login_enqueue_scripts hooks. This notice was triggered by the cf7_rm_script handle. Please see Debugging in WordPress for more information. (This message was added in version 3.3.0.)
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/form-list.php+10
    Undefined index: formId
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/form-list.php+10
    Undefined offset: 0
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/form-list.php+10
    Trying to get property 'ID' of non-object
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+80
    Undefined property: stdClass::$email_field
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+84
    Undefined property: stdClass::$from_name
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+86
    Undefined property: stdClass::$from_mail
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+88
    Undefined property: stdClass::$reply_to
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+90
    Undefined property: stdClass::$cc
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+92
    Undefined property: stdClass::$bcc
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+97
    Undefined property: stdClass::$approval_subject
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+99
    Undefined property: stdClass::$approval_message
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+146
    Undefined variable: file_info
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+146
    Trying to access array offset on value of type null
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+127
    Undefined property: stdClass::$rejection_subject
    • > GET request to /wp-admin/admin.php?page=cf7_reply_manager-settings
    • > Notice in wp-content/plugins/cf7-reply-manager/admin/partials/replies.php+129
    Undefined property: stdClass::$rejection_message

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
The following issues need your attention
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/cf7-reply-manager/admin/class-cf7-reply-manager-admin.php:5

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

readme.txt 88% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that require attention:
  • Screenshots: Please a description for screenshot #3 in cf7-reply-manager/assets to your readme.txt
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === cf7-reply-manager === )
You can take inspiration from this readme.txt

cf7-reply-manager/contact-form-7-reply-manager.php 77% from 13 tests

The entry point to "CF7 Reply Manager" version 1.2.3 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("cf7-reply-manager.php" instead of "contact-form-7-reply-manager.php")
  • Domain Path: The domain path folder does not exist ("/languages")
  • Text Domain: The text domain should only use lowercase characters and dashes

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
There were no executable files found in this plugin1,029 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP7128180564
CSS25914283
JavaScript22934182

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity5.00
▷ Minimum class complexity4.00
▷ Maximum class complexity7.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods7
▷ Static methods228.57%
▷ Public methods685.71%
▷ Protected methods00.00%
▷ Private methods114.29%
Functions21
▷ Named functions1885.71%
▷ Anonymous functions314.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
5 compressed PNG files occupy 0.00MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/css/DataTables-1.10.18/images/sort_desc_disabled.png0.14KB0.25KB0.00%
admin/css/DataTables-1.10.18/images/sort_desc.png0.15KB0.25KB0.00%
admin/css/DataTables-1.10.18/images/sort_asc.png0.16KB0.25KB0.00%
admin/css/DataTables-1.10.18/images/sort_asc_disabled.png0.14KB0.25KB0.00%
admin/css/DataTables-1.10.18/images/sort_both.png0.20KB0.29KB0.00%