10% comments-to-activecampaign

Code Review | Comments To ActiveCampaign

WordPress plugin Comments To ActiveCampaign scored10%from 54 tests.

About plugin

  • Plugin page: comments-to-activ...
  • Plugin version: 1.0
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Dec 28, 2016
  • Latest release: Mar 30, 2023
  • Number of updates: 12
  • Update frequency: every 189.8 days
  • Top authors: haktansuren (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /2,132 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The following installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Parse error in wp-content/plugins/comments-to-activecampaign/metabox.php+60
    syntax error, unexpected end of file, expecting elseif (T_ELSEIF) or else (T_ELSE) or endif (T_ENDIF)

Server metrics [RAM: ▲0.00MB] [CPU: ▼2.91ms] Passed 4 tests

Server-side resources used by Comments To ActiveCampaign
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0039.43 ▼3.53
Dashboard /wp-admin3.31 ▲0.0051.91 ▲3.46
Posts /wp-admin/edit.php3.36 ▲0.0048.05 ▼4.54
Add New Post /wp-admin/post-new.php5.89 ▲0.0093.54 ▼2.96
Media Library /wp-admin/upload.php3.23 ▲0.0035.00 ▼0.62

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Comments To ActiveCampaign
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲6813.19 ▼1.564.90 ▲2.9743.57 ▼4.54
Dashboard /wp-admin2,206 ▲185.85 ▼0.05101.32 ▼5.4539.03 ▼3.84
Posts /wp-admin/edit.php2,089 ▼02.05 ▼0.0040.84 ▼0.7935.40 ▼1.52
Add New Post /wp-admin/post-new.php1,533 ▲1423.28 ▼0.02665.97 ▼16.7358.13 ▲4.10
Media Library /wp-admin/upload.php1,388 ▼04.20 ▼0.1893.89 ▼9.5240.99 ▼2.97

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

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
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 24× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/comments-to-activecampaign/ac/List.class.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/comments-to-activecampaign/admin-menu.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/comments-to-activecampaign/ac/Form.class.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/comments-to-activecampaign/ac/Webhook.class.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/comments-to-activecampaign/ac/Message.class.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/comments-to-activecampaign/ac/Settings.class.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/comments-to-activecampaign/ac/Design.class.php:3
    • > PHP Fatal error
      Uncaught Error: Class 'ActiveCampaign' not found in wp-content/plugins/comments-to-activecampaign/ac/Campaign.class.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/comments-to-activecampaign/comments-to-activecampaign.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/comments-to-activecampaign/activecampaign.php:50

User-side errors Passed 1 test

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

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
5 plugin tags: comments to leads, comments to activecampaign, comments, activecampaign, leads

comments-to-activecampaign/comments-to-activecampaign.php Passed 13 tests

The primary PHP file in "Comments To ActiveCampaign" version 1.0 is used by WordPress to initiate all plugin functionality
71 characters long description:
The simplest way to collect leads from your comments to ActiveCampaign.

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
Good job! No executable or dangerous file extensions detected1,714 lines of code in 29 files:
LanguageFilesBlank linesComment linesLines of code
PHP283531291,700
JavaScript11114

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.19
Average class complexity7.48
▷ Minimum class complexity1.00
▷ Maximum class complexity55.00
Average method complexity1.87
▷ Minimum method complexity1.00
▷ Maximum method complexity44.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes21
▷ Abstract classes00.00%
▷ Concrete classes21100.00%
▷ Final classes00.00%
Methods157
▷ Static methods00.00%
▷ Public methods157100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions11
▷ Named functions11100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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