74% w3swoozoho

Code Review | WooCommerce to Zoho CRM

WordPress plugin WooCommerce to Zoho CRM scored74%from 54 tests.

About plugin

  • Plugin page: w3swoozoho
  • Plugin version: 1.3.0
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-6.2
  • WordPress version: 6.3.1
  • First release: Apr 15, 2020
  • Latest release: May 19, 2023
  • Number of updates: 24
  • Update frequency: every 47.0 days
  • Top authors: w3scloud (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

40+ active /1,434 total downloads

Benchmarks

Plugin footprint 65% 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.77MB] [CPU: ▼2.49ms] Passed 4 tests

Server-side resources used by WooCommerce to Zoho CRM
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.97 ▲0.5144.73 ▲4.01
Dashboard /wp-admin4.17 ▲0.8748.27 ▼2.37
Posts /wp-admin/edit.php4.24 ▲0.8854.44 ▲3.30
Add New Post /wp-admin/post-new.php6.78 ▲0.8977.53 ▼14.42
Media Library /wp-admin/upload.php4.04 ▲0.8139.56 ▲3.53
W3S Woo Zoho /wp-admin/admin.php?page=w3swoozoho_settings4.0437.72
Install Plugins /wp-admin/admin.php?page=w3swoozoho_settings_required_plugins4.0738.10

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 304 new files
Database: 1 new table, 8 new options
New tables
wp_w3swoozoho_auths
New WordPress options
widget_recent-posts
db_upgraded
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget
w3swoozoho_crm
w3swoozoho_installed
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for WooCommerce to Zoho CRM
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,077 ▲34215.00 ▲0.601.75 ▼0.4141.37 ▼3.43
Dashboard /wp-admin2,483 ▲2986.68 ▲0.77138.84 ▲28.7245.20 ▼3.40
Posts /wp-admin/edit.php2,398 ▲3093.55 ▲1.5050.66 ▲11.5034.72 ▼0.11
Add New Post /wp-admin/post-new.php1,578 ▲4523.27 ▼0.09654.33 ▼8.0634.99 ▼17.33
Media Library /wp-admin/upload.php1,536 ▲1484.41 ▲0.1981.19 ▼21.4545.65 ▲1.42
W3S Woo Zoho /wp-admin/admin.php?page=w3swoozoho_settings1,2633.6348.9333.75
Install Plugins /wp-admin/admin.php?page=w3swoozoho_settings_required_plugins1,2363.3940.9228.89

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • This plugin does not fully uninstall, leaving 1 table in the database
    • wp_w3swoozoho_auths
  • This plugin did not uninstall successfully, leaving 8 options in the database
    • w3swoozoho_crm
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • w3swoozoho_installed
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check 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
  • 34× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/w3swoozoho/vendor/tareq1988/wordpress-settings-api-class/example/procedural-example.php:270
    • > PHP Fatal error
      Uncaught Error: Class 'zcrmsdk\\crm\\setup\\restclient\\ZCRMRestClient' not found in wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/samplecodes/tagAPI.php:10
    • > PHP Warning
      require_once(wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/samplecodes/../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/samplecodes/rest.php on line 3
    • > PHP Fatal error
      Uncaught Error: Class 'zcrmsdk\\crm\\api\\handler\\APIHandler' not found in wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/src/crm/api/handler/VariableAPIHandler.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'zcrmsdk\\crm\\api\\handler\\APIHandler' not found in wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/src/crm/api/handler/RelatedListAPIHandler.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'zcrmsdk\\crm\\api\\handler\\APIHandler' not found in wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/src/crm/bulkapi/handler/BulkReadAPIHandler.php:15
    • > PHP Fatal error
      Uncaught Error: Class 'zcrmsdk\\crm\\api\\response\\CommonAPIResponse' not found in wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/src/crm/api/response/APIResponse.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'zcrmsdk\\crm\\api\\handler\\APIHandler' not found in wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/src/crm/api/handler/MassEntityAPIHandler.php:12
    • > PHP Warning
      require_once(wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/samplecodes/../vendor/autoload.php): failed to open stream: No such file or directory in wp-content/plugins/w3swoozoho/vendor/zohocrm/php-sdk/samplecodes/record.php on line 2
    • > PHP Fatal error
      Uncaught Error: Interface 'zcrmsdk\\oauth\\persistence\\ZohoOAuthPersistenceInterface' not found in wp-content/plugins/w3swoozoho/inc/Zoho/Auth/CRMOAuthPersistence.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: w3scloud, crm, woocommerce, zoho, woocommerce to zoho...

w3swoozoho/w3swoozoho.php Passed 13 tests

The primary PHP file in "WooCommerce to Zoho CRM" version 1.3.0 is used by WordPress to initiate all plugin functionality
74 characters long description:
Connect Zoho with WooCommerce. Send customer information to your Zoho CRM.

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin52,688 lines of code in 254 files:
LanguageFilesBlank linesComment linesLines of code
PHP23011,12327,13651,754
Markdown31880510
JSON500200
JavaScript33459194
CSS122029
SVG1001

PHP code 50% from 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Please fix the following
  • Please reduce cyclomatic complexity of classes to less than 1000 (currently 3,079)
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity38.79
▷ Minimum class complexity1.00
▷ Maximum class complexity3,079.00
Average method complexity3.02
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces24
Interfaces3
Traits0
Classes160
▷ Abstract classes21.25%
▷ Concrete classes15898.75%
▷ Final classes10.63%
Methods3,075
▷ Static methods34811.32%
▷ Public methods2,59084.23%
▷ Protected methods381.24%
▷ Private methods44714.54%
Functions102
▷ Named functions9896.08%
▷ Anonymous functions43.92%
Constants267
▷ Global constants10238.20%
▷ Class constants16561.80%
▷ Public constants165100.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
3 PNG files occupy 0.40MB with 0.21MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
vendor/tareq1988/wordpress-settings-api-class/screenshot-1.png389.59KB115.93KB▼ 70.24%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%