77% bit-form

Code Review | Contact Form Builder Plugin: Multi Step Contact Form, WPForm Contact Form, Payment Form, WP Forms Contact Form Plugin – Bit Form

WordPress plugin Contact Form Builder Plugin: Multi Step Contact Form, WPForm Contact Form, Payment Form, WP Forms Contact Form Plugin – Bit Form scored77%from 54 tests.

About plugin

  • Plugin page: bit-form
  • Plugin version: 2.9.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Sep 5, 2020
  • Latest release: Nov 28, 2023
  • Number of updates: 187
  • Update frequency: every 6.3 days
  • Top authors: bitpressadmin (97.86%)bitpressdeveloper (2.67%)

Code review

54 tests

User reviews

59 reviews

Install metrics

3,000+ active /78,144 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.57MB] [CPU: ▲7.95ms] Passed 4 tests

Analyzing server-side resources used by Contact Form Builder Plugin: Multi Step Contact Form, WPForm Contact Form, Payment Form, WP Forms Contact Form Plugin – Bit Form
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /4.13 ▲0.6656.02 ▲12.92
Dashboard /wp-admin3.87 ▲0.5362.90 ▲2.68
Posts /wp-admin/edit.php3.91 ▲0.5563.58 ▲13.87
Add New Post /wp-admin/post-new.php7.04 ▲1.15104.26 ▲2.31
Media Library /wp-admin/upload.php3.78 ▲0.5551.72 ▲15.88

Server storage [IO: ▲38.54MB] [DB: ▲0.02MB] 67% from 3 tests

Analyzing filesystem and database footprints of this plugin
Please try to fix the following items
  • Total filesystem usage must be limited to 25MB (currently using 38.54MB)
Filesystem: 2,588 new files
Database: 11 new tables, 11 new options
New tables
wp_bitforms_form_entry_relatedinfo
wp_bitforms_form_entrymeta
wp_bitforms_form_log_details
wp_bitforms_success_messages
wp_bitforms_form_entry_log
wp_bitforms_email_template
wp_bitforms_reports
wp_bitforms_form_entries
wp_bitforms_workflows
wp_bitforms_form
...
New WordPress options
bitforms_installed
bitform_app_config
widget_theysaidso_widget
bitforms_migrated_to_v2
widget_recent-comments
can_compress_scripts
db_upgraded
theysaidso_admin_options
bitforms_version
widget_recent-posts
...

Browser metrics Passed 4 tests

Contact Form Builder Plugin: Multi Step Contact Form, WPForm Contact Form, Payment Form, WP Forms Contact Form Plugin – Bit Form: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,839 ▲9214.20 ▼0.521.73 ▲0.0638.60 ▼6.02
Dashboard /wp-admin2,247 ▲725.63 ▼0.0589.60 ▼20.4840.91 ▲0.29
Posts /wp-admin/edit.php2,156 ▲561.99 ▲0.0441.02 ▲2.2636.38 ▲0.85
Add New Post /wp-admin/post-new.php6,227 ▲4,70119.17 ▼4.13940.24 ▲302.3655.30 ▲2.99
Media Library /wp-admin/upload.php1,452 ▲584.25 ▲0.1098.58 ▲2.7541.49 ▲0.35
Doc & Support /wp-admin/admin.php?page=bitform#/doc-support1,00310.53199.50119.14
All Forms /wp-admin/admin.php?page=bitform#/2,27316.58158.6192.66
SMTP /wp-admin/admin.php?page=bitform#/app-settings/smtp1,14311.12170.69101.28
App Settings /wp-admin/admin.php?page=bitform#/app-settings/recaptcha1,09811.95151.59105.46
Payments /wp-admin/admin.php?page=bitform#/app-settings/payments98610.80301.74127.79

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
  • Zombie WordPress options were found after uninstall: 6 options
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

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

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 6× PHP files output text when accessed directly:
    • > /wp-content/plugins/bit-form/views/preview-page.php
    • > /wp-content/plugins/bit-form/views/conversational-form.php
    • > /wp-content/plugins/bit-form/views/form-not-found.php
    • > /wp-content/plugins/bit-form/views/standalone-form.php
    • > /wp-content/plugins/bit-form/vendor/arif-un/jcof/tests/test.php
    • > /wp-content/plugins/bit-form/v1/assets/js/index.php
  • 92× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'BitCode\\BitForm\\Core\\Database\\Model' not found in wp-content/plugins/bit-form/includes/Core/Database/EmailTemplateModel.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'BitCode\\BitForm\\Core\\Database\\Model' not found in wp-content/plugins/bit-form/includes/Core/Database/FormEntryLogModel.php:11
    • > PHP Warning
      Use of undefined constant BITFORMS_UPLOAD_BASE_URL - assumed 'BITFORMS_UPLOAD_BASE_URL' (this will throw an Error in a future version of PHP) in wp-content/plugins/bit-form/views/preview-page.php on line 46
    • > PHP Fatal error
      Uncaught Error: Class 'BitCode\\BitForm\\Admin\\Form\\Template\\TemplateBase' not found in wp-content/plugins/bit-form/v1/includes/Admin/Form/Template/ContactFormTemplate.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'BitCode\\BitForm\\Core\\Form\\FormManager' not found in wp-content/plugins/bit-form/v1/includes/Frontend/Form/FrontendFormManager.php:25
    • > PHP Notice
      Undefined variable: formID in wp-content/plugins/bit-form/views/standalone-form.php on line 41
    • > PHP Warning
      Use of undefined constant BITFORMS_CONTENT_DIR - assumed 'BITFORMS_CONTENT_DIR' (this will throw an Error in a future version of PHP) in wp-content/plugins/bit-form/views/preview-page.php on line 28
    • > PHP Notice
      Undefined variable: formID in wp-content/plugins/bit-form/views/entry-edit-page.php on line 19
    • > PHP Fatal error
      Uncaught Error: Class 'BitCode\\BitForm\\Core\\Integration\\WebHooks\\WebHooksHandler' not found in wp-content/plugins/bit-form/includes/Core/Integration/Pabbly/PabblyHandler.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'BitCode\\BitForm\\Core\\Database\\Model' not found in wp-content/plugins/bit-form/includes/Core/Database/ApiModel.php:11

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: These screenshots need descriptions #1, #2, #3, #4, #5, #6 in bit-form/assets to your readme.txt
  • Tags: You are using too many tags: 12 tag instead of maximum 10
You can look at the official readme.txt

bit-form/bitforms.php 92% from 13 tests

Analyzing the main PHP file in "Contact Form Builder Plugin: Multi Step Contact Form, WPForm Contact Form, Payment Form, WP Forms Contact Form Plugin – Bit Form" version 2.9.0
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("bit-form.php" instead of "bitforms.php")

Code Analysis 97% from 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 plugin77,950 lines of code in 1,850 files:
LanguageFilesBlank linesComment linesLines of code
PHP3479,2734,39255,758
JSON120014,850
JavaScript1,3913043005,499
SVG781191,810
CSS210821
Markdown14012

PHP code 50% from 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
It is recommended to fix the following
  • Please reduce cyclomatic complexity of methods to less than 100 (currently 108)
Cyclomatic complexity
Average complexity per logical line of code0.52
Average class complexity30.10
▷ Minimum class complexity1.00
▷ Maximum class complexity423.00
Average method complexity5.99
▷ Minimum method complexity1.00
▷ Maximum method complexity108.00
Code structure
Namespaces87
Interfaces0
Traits0
Classes320
▷ Abstract classes10.31%
▷ Concrete classes31999.69%
▷ Final classes9429.47%
Methods1,853
▷ Static methods52028.06%
▷ Public methods1,53182.62%
▷ Protected methods1035.56%
▷ Private methods21911.82%
Functions62
▷ Named functions3861.29%
▷ Anonymous functions2438.71%
Constants26
▷ Global constants2492.31%
▷ Class constants27.69%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
686 compressed PNG files occupy 0.32MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
static/countries/fr.png0.11KB0.11KB▼ 2.59%
v1/static/countries/pg.png0.38KB0.38KB0.25%
static/currencies/gyd.png0.77KB0.48KB▼ 36.82%
v1/static/countries/ye.png0.12KB0.12KB0.00%
static/countries/mo.png0.25KB0.25KB0.00%