78% flamix-bitrix24-and-wpforms-integration

Code Review | Flamix: Bitrix24 and WPForms integration

WordPress plugin Flamix: Bitrix24 and WPForms integration scored78%from 54 tests.

About plugin

  • Plugin page: flamix-bitrix24-a...
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.2
  • WordPress version: 6.3.1
  • First release: Jun 3, 2023
  • Latest release: Jul 1, 2023
  • Number of updates: 5
  • Update frequency: every 5.6 days
  • Top authors: flamix (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /111 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.20MB] [CPU: ▼9.04ms] Passed 4 tests

Server-side resources used by Flamix: Bitrix24 and WPForms integration
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.70 ▲0.2338.67 ▼2.27
Dashboard /wp-admin3.56 ▲0.2150.30 ▼11.18
Posts /wp-admin/edit.php3.61 ▲0.2544.48 ▼4.65
Add New Post /wp-admin/post-new.php6.07 ▲0.1881.43 ▼18.04
Media Library /wp-admin/upload.php3.42 ▲0.1841.73 ▲9.10
Bitrix24 ← WPForms /wp-admin/options-general.php?page=flamix-bitrix24-and-wpforms-integration/includes/local/Settings/Menu.php3.4533.37
Bitrix24 integration /wp-admin/admin.php?page=flamix-bitrix24-and-wpforms-integration/includes/local/Settings/Menu.php3.4533.31

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 441 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
db_upgraded
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for Flamix: Bitrix24 and WPForms integration
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.20 ▼1.391.76 ▼0.0843.90 ▲0.39
Dashboard /wp-admin2,210 ▲214.87 ▼0.00110.23 ▲5.3944.05 ▲1.08
Posts /wp-admin/edit.php2,093 ▲12.04 ▲0.0137.48 ▼5.9234.95 ▼4.02
Add New Post /wp-admin/post-new.php1,536 ▼623.32 ▲5.10647.99 ▲19.5651.40 ▲2.54
Media Library /wp-admin/upload.php1,392 ▲44.20 ▼0.0196.34 ▼3.9442.55 ▼0.77
Bitrix24 ← WPForms /wp-admin/options-general.php?page=flamix-bitrix24-and-wpforms-integration/includes/local/Settings/Menu.php9302.1823.5433.57
Bitrix24 integration /wp-admin/admin.php?page=flamix-bitrix24-and-wpforms-integration/includes/local/Settings/Menu.php9102.3426.6128.43

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Everything seems fine, however this is by no means an exhaustive test

SRP 0% 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 fix the following
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/mobiledetect/mobiledetectlib/export/exportToJSON.php
  • 177× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Component\\VarDumper\\Caster\\EnumStub' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/symfony/var-dumper/Caster/ArgsStub.php:21
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\MessageInterface' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/psr/http-message/src/ResponseInterface.php:20
    • > PHP Fatal error
      Uncaught Error: Class 'GuzzleHttp\\Cookie\\CookieJar' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\Handler\\AbstractProcessingHandler' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/monolog/monolog/src/Monolog/Handler/FirePHPHandler.php:24
    • > PHP Fatal error
      Uncaught Error: Interface 'Monolog\\Processor\\ProcessorInterface' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/monolog/monolog/src/Monolog/Processor/TagProcessor.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\Handler\\StreamHandler' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/monolog/monolog/src/Monolog/Handler/RotatingFileHandler.php:27
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\Handler\\AbstractProcessingHandler' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/monolog/monolog/src/Monolog/Handler/SqsHandler.php:23
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\ResponseInterface' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/guzzlehttp/psr7/src/Response.php:13
    • > PHP Fatal error
      Uncaught Error: Class 'Monolog\\Handler\\MailHandler' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/monolog/monolog/src/Monolog/Handler/SendGridHandler.php:21
    • > PHP Fatal error
      Uncaught Error: Interface 'Symfony\\Component\\VarDumper\\Command\\Descriptor\\DumpDescriptorInterface' not found in wp-content/plugins/flamix-bitrix24-and-wpforms-integration/includes/vendor/symfony/var-dumper/Command/Descriptor/CliDescriptor.php:27

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 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
These attributes need your attention:
  • Tags: There are too many tags (11 tag instead of maximum 10)
The official readme.txt is a good inspiration

flamix-bitrix24-and-wpforms-integration/flamix-bitrix24-and-wpforms-integration.php Passed 13 tests

The entry point to "Flamix: Bitrix24 and WPForms integration" version 1.0.0 is a PHP file that has certain tags in its header comment area
42 characters long description:
Bitrix24 and WordPress WPForms integration

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected37,518 lines of code in 414 files:
LanguageFilesBlank linesComment linesLines of code
PHP3526,06414,43130,024
Markdown341,89305,220
JSON24002,099
CSS100130
XML10020
YAML11015
JavaScript10010

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity12.64
▷ Minimum class complexity1.00
▷ Maximum class complexity166.00
Average method complexity3.00
▷ Minimum method complexity1.00
▷ Maximum method complexity78.00
Code structure
Namespaces46
Interfaces43
Traits10
Classes270
▷ Abstract classes103.70%
▷ Concrete classes26096.30%
▷ Final classes4818.46%
Methods1,899
▷ Static methods45624.01%
▷ Public methods1,47877.83%
▷ Protected methods19410.22%
▷ Private methods22711.95%
Functions244
▷ Named functions12250.00%
▷ Anonymous functions12250.00%
Constants212
▷ Global constants104.72%
▷ Class constants20295.28%
▷ Public constants14471.29%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 PNG file occupies 0.05MB with 0.04MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
includes/vendor/flamix/conversions/img/form_example.png53.11KB16.68KB▼ 68.59%