Code Analysis: Omnisend for Woocommerce 1.11.12

Function Rating Maintainability Complexity Lines of code
Omnisend_Product::__construct()
D
18
72 203
Omnisend_Order::__construct()
D
19
57 197
Omnisend_Contact::__construct()
D
27
55 113
Omnisend_Manager_Assistant::batchCheck()
D
32 40 83
omnisend_show_sync()
C
28
23 176
Omnisend_Cart::__construct()
B
38 24 58
Omnisend_Manager::pushProductToOmnisend()
B
41 17 48
Omnisend_Manager_Assistant::syncAllOrders()
B
37 14 77
Omnisend_Manager_Assistant::syncAllContacts()
A
38 13 70
omnisend_show_logs()
A
39 12 70
Omnisend_Manager_Assistant::syncAllProducts()
A
38 12 70
Omnisend_Helper::omnisendApi()
A
39 12 66
Omnisend_Plugin_Event::connection_event()
A
46 13 45
Omnisend_Manager::pushContactToOmnisend()
A
44 11 43
Omnisend_Manager::pushCartToOmnisend()
A
45 11 40
Omnisend_Manager::updateOrderStatus()
A
47 11 32
Omnisend_Manager::pushOrderToOmnisend()
A
46 10 36
Omnisend_Manager::pushCategoryToOmnisend()
A
47 10 32
omnisendRestoreCart()
A
45 9 39
Omnisend_Manager::updateAccountInfo()
A
53 9 19
omnisend_plugin_updates()
A
52 8 25
omnisend_update_contact_status()
A
44 6 46
Omnisend_Ajax::identifyByEmail()
S
50 7 27
Omnisend_Install::delete_omnisend_webhooks()
S
52 7 23
Omnisend_Logger::hook()
S
54 7 19
Omnisend_Cart::setCartId()
S
55 7 19
Omnisend_Helper::getAccountInfo()
S
50 6 26
displayTagSettings()
S
53 6 24
Omnisend_Helper::check_wp_wc_compatibility()
S
52 6 24
omnisend_handle_settings_page_actions()
S
55 6 21
displayConnectionInfo()
S
45 3 65
Omnisend_Contact_Resolver::updateByUserId()
S
56 6 17
Omnisend_Helper::getClientIp()
S
65 7 9
display_sync_actions()
S
55 5 29
Omnisend_Event_Tracker::trackEvent()
S
52 5 25
omnisend_show_settings_page()
S
56 5 20
Omnisend_Connection_Error::__construct()
S
56 5 20
Omnisend_Manager_Assistant::syncAllCategories()
S
57 5 18
Omnisend_Product::checkIfSubcategoriesInProductArray()
S
57 5 17
display_notice()
S
53 4 30
has_sync_stats_error()
S
62 5 15
has_sync_stats_skipped()
S
62 5 15
has_sync_stats_not_synced()
S
62 5 15
Omnisend_Logs::send()
S
58 5 15
Omnisend_Sync_Manager::areDataSyncing()
S
61 5 15
omnisend_add_order_status_url_to_webhook_payload()
S
62 5 11
omnisend_rebuild_cart()
S
51 4 26
validate_connect_token()
S
52 4 26
Omnisend_Logs_Sender::send()
S
51 4 25
Omnisend_Helper::omnisendPluginVersion()
S
56 4 17
Omnisend_Category::createFromId()
S
64 5 9
omnisend_handle_sync_page_actions()
S
62 4 13
Omnisend_Helper::cleanModelFromEmptyFields()
S
61 4 13
Omnisend_Sync_Manager::isAllBatchesSyncFinished()
S
63 4 12
Omnisend_Manager_Assistant::unsetUserCart()
S
61 4 12
omnisend_admin_scripts_and_styles()
S
53 3 25
get_system_status()
S
52 3 24
Omnisend_Sync_Stats_Repository::get_contact_stats()
S
46 1 51
display_connection_error_notice()
S
51 2 33
connect_omnisend_account()
S
56 3 18
show_api_access_notice()
S
58 3 18
omnisend_add_checkout_script()
S
57 3 17
omnisend_order_created()
S
60 3 14
Omnisend_Product::productPicker()
S
60 3 14
Omnisend_Contact_Resolver::resolveEmailToContactId()
S
59 3 14
Omnisend_Sync_Manager::startContactsIfNotFinished()
S
59 3 14
Omnisend_Sync_Manager::startOrdersIfNotFinished()
S
59 3 14
Omnisend_Sync_Manager::startProductsIfNotFinished()
S
59 3 14
Omnisend_Sync_Stats_Repository::get_stats_from_posts()
S
51 2 28
Omnisend_Sync_Manager::startCategoriesIfNotFinished()
S
60 3 13
Omnisend_Helper::is_woocommerce_api_access_granted()
S
60 3 13
Omnisend_Cart_Event::build_event_props()
S
51 2 27
Omnisend_Contact_Resolver::updateByEmail()
S
61 3 12
omnisend_activated()
S
64 3 12
displayPermalinkNotice()
S
56 2 23
omnisend_woocommerce_menu()
S
54 2 22
displayConnection()
S
59 2 18
display_resync_all_contacts()
S
64 2 17
Omnisend_Logger::log()
S
58 2 16
omnisend_cart_delete()
S
67 3 9
trackOauthDeny()
S
69 3 7
Omnisend_Cart_Event::build_checkout_url()
S
58 2 15
omisend_restore_cart_page()
S
68 3 8
Omnisend_Category::__construct()
S
68 3 7
Omnisend_Manager::isSetup()
S
66 3 9
Omnisend_Server_Session::isSessionAvailable()
S
66 3 9
Omnisend_Contact_Resolver::getContactIdFromOmnisend()
S
61 3 10
omnisend_rebuild_cart_page()
S
68 3 9
Omnisend_Sync_Manager::finishCheckBatches()
S
70 3 6
Omnisend_Tracker::track_plugin_event()
S
58 2 15
Omnisend_User_Storage::get()
S
63 3 9
Omnisend_Install::revoke_omnisend_woo_api_keys()
S
65 3 9
show_connection_notice()
S
62 2 15
Omnisend_Cart_Event::addedProductToCart()
S
68 3 8
omnisend_uninstall()
S
57 2 15
is_omnisend_cart_rebuild_url()
S
78 3 3
Omnisend_Tracker::track()
S
60 2 14
Omnisend_Event_Tracker::track()
S
61 2 13
Omnisend_Sync_Stats_Repository::get_category_stats()
S
52 1 28
generate_install_url()
S
60 2 13
display_success()
S
66 2 11
displayWooCoomerceNotInstalledOrDisabled()
S
58 1 22
displayUnsupportedWordPressVersion()
S
59 1 22
Omnisend_Manager_Assistant::getNotSyncedCategories()
S
57 1 18
Omnisend_Logger::ensure_logging_table_exists()
S
59 1 16
displayCheckoutOptInCheckboxSettings()
S
62 1 16
omnisend_checkbox_custom_checkout_field()
S
59 1 16
Omnisend_Sync_Manager::stopProducts()
S
71 2 6
Omnisend_Sync::wasOrderSyncedBefore()
S
73 2 4
Omnisend_Contact_Resolver::updateByEmailAndContactId()
S
67 2 7
Omnisend_Manager::deleteProductFromOmnisend()
S
67 2 7
Omnisend_Sync_Manager::stopOrders()
S
71 2 6
Omnisend_Cart_Event::startedCheckout()
S
73 2 5
Omnisend_Server_Session::get()
S
71 2 6
Omnisend_Manager_Assistant::getList()
S
64 2 9
omnisend_on_product_change()
S
69 2 7
Omnisend_Sync_Manager::isContactsFinished()
S
71 2 6
Omnisend_Helper::validCountryCode()
S
71 2 6
Omnisend_Sync_Manager::finishOrders()
S
69 2 7
displaySettings()
S
63 1 15
Omnisend_Sync_Manager::isOrdersFinished()
S
71 2 6
omnisend_activation()
S
72 2 6
Omnisend_Sync_Stats_Repository::get_array_field_or_zero()
S
78 2 3
Omnisend_Product::get_unhidden_variations()
S
66 2 9
Omnisend_Sync_Manager::areProductsSyncing()
S
71 2 6
display_api_access_notice()
S
68 2 8
Omnisend_Sync_Manager::finishCategories()
S
69 2 7
Omnisend_Ajax::triggerCartPush()
S
74 2 5
Omnisend_Install::notify_about_plugin_activation()
S
64 2 10
Omnisend_Order::create()
S
69 2 7
omnisend_activate()
S
72 2 6
Omnisend_Sync::wasCategorySyncedBefore()
S
74 2 4
Omnisend_Sync_Manager::areCategoriesSyncing()
S
71 2 6
omnisend_order_updated()
S
73 2 6
omnisend_product_picker()
S
68 2 8
Omnisend_Sync_Manager::finishProducts()
S
69 2 7
track_started_checkout_event()
S
67 2 7
Omnisend_Sync_Manager::isCategoriesFinished()
S
71 2 6
hook_omnisend_ajax_save_email()
S
67 2 7
Omnisend_Sync_Manager::finishContacts()
S
69 2 7
Omnisend_Sync_Manager::startCheckBatchesIfNotStarted()
S
68 2 7
omnisend_product_delete()
S
73 2 6
omnisend_deactivate()
S
72 2 6
Omnisend_Sync_Manager::areContactsSyncing()
S
71 2 6
Omnisend_Sync_Manager::isProductsFinished()
S
71 2 6
track_connection_event()
S
71 2 6
omnisend_cart_updated()
S
71 2 7
omnisend_category_delete()
S
73 2 6
Omnisend_Sync_Manager::stopCategories()
S
71 2 6
Omnisend_Helper::validatePhoneNumber()
S
63 2 10
Omnisend_Server_Session::set()
S
68 2 7
Omnisend_Manager::deleteCategoryFromOmnisend()
S
67 2 7
Omnisend_Logger::remove_old_synced_logs()
S
66 2 8
Omnisend_Contact::create()
S
69 2 7
Omnisend_Cart::create()
S
70 2 7
Omnisend_Logger::debug()
S
73 2 5
Omnisend_Product::create()
S
69 2 7
Omnisend_Logs::init()
S
72 2 5
Omnisend_Sync_Manager::areOrdersSyncing()
S
71 2 6
Omnisend_Logs::sync()
S
66 2 8
Omnisend_Install::notify_about_plugin_update()
S
64 2 10
Omnisend_Product::getProductCategoryParent()
S
63 2 10
Omnisend_Sync_Manager::stopContacts()
S
71 2 6
Omnisend_Ajax::generateContactPayload()
S
64 2 9
Omnisend_Helper::getWCAuthUrl()
S
59 1 13
displayOmnisendConnected()
S
64 1 13
Omnisend_Sync_Manager::startResyncAllWithErrorOrSkipped()
S
63 1 11
omnisend_add_schedules()
S
63 1 11
Omnisend_Logger::error()
S
78 1 3
displayPluginVersion()
S
68 1 10
omnisend_init_categories_sync()
S
79 1 4
Omnisend_Sync_Manager::startResyncContacts()
S
75 1 4
Omnisend_Sync_Stats_Repository::count_item()
S
71 1 5
Omnisend_Operation_Status::toString()
S
68 1 8
Omnisend_Install::get_woo_api_keys()
S
71 1 5
Omnisend_Connection_Error::get_message()
S
82 1 3
Omnisend_Install::remove_woo_api_key()
S
71 1 5
Omnisend_Sync_Manager::startContacts()
S
77 1 4
Omnisend_Sync_Manager::startCategories()
S
77 1 4
Omnisend_Category::toArray()
S
72 1 6
omnisend_sync_logs()
S
83 1 3
omnisend_on_category_change()
S
74 1 5
Omnisend_Sync_Manager::startProducts()
S
77 1 4
Omnisend_Logs::get_last_log_id()
S
74 1 4
Omnisend_Sync_Stats::__construct()
S
67 1 8
generate_registration_url()
S
67 1 8
Omnisend_Plugin_Event::permalinks_notice_shown()
S
80 1 3
Omnisend_Logger::get_logs()
S
71 1 5
omnisend_wplogin()
S
78 1 4
omnisend_on_user_register()
S
75 1 5
Omnisend_Sync_Manager::startOrders()
S
77 1 4
Omnisend_Sync::markOrderSyncAsSkipped()
S
79 1 3
Omnisend_Operation_Status::error()
S
79 1 3
Omnisend_User_Storage::setContactId()
S
79 1 3
Omnisend_Sync::markCategorySyncAsSynced()
S
78 1 3
omnisend_order_refunded()
S
76 1 4
omnisend_init_contacts_sync()
S
79 1 4
omnisend_front_scripts_and_styles()
S
67 1 7
Omnisend_Plugin_Event::api_key_saved()
S
80 1 3
omnisend_order_payment_failed()
S
76 1 4
omnisend_order_payment_completed()
S
76 1 4
omnisend_init_products_sync()
S
79 1 4
Omnisend_User_Storage::set()
S
66 1 7
Omnisend_Operation_Status::success()
S
79 1 3
Omnisend_Contact_Resolver::getStorageKey()
S
80 1 3
Omnisend_User_Storage::getContactId()
S
79 1 3
Omnisend_Sync_Stats_Repository::get_product_stats()
S
79 1 3
omnisend_order_completed()
S
76 1 4
Omnisend_Sync_Stats_Repository::get_all_stats()
S
66 1 9
Omnisend_Helper::arePermalinksCorrect()
S
75 1 4
Omnisend_Logger::enable_logging()
S
76 1 4
omnisend_on_user_update()
S
75 1 5
Omnisend_Manager_Assistant::getEmailFromOmnisend()
S
71 1 5
Omnisend_Plugin_Event::plugin_updated()
S
80 1 3
Omnisend_Logger::disable_logging()
S
80 1 3
Omnisend_Sync::getOrderSyncStatus()
S
78 1 3
Omnisend_Sync::markContactAsError()
S
79 1 3
Omnisend_Logger::is_logging_enabled()
S
80 1 3
Omnisend_Logger::get_all_logs()
S
75 1 4
Omnisend_Sync::markContactAsSynced()
S
78 1 3
Omnisend_Operation_Status::__construct()
S
77 1 4
omnisend_order_pending()
S
76 1 4
Omnisend_Helper::priceToCents()
S
77 1 3
is_omnisend_account_connected()
S
79 1 3
Omnisend_Plugin_Event::sync_settings_shown()
S
80 1 3
add_plugin_settings_link()
S
71 1 5
omnisend_batch_check()
S
79 1 4
omnisend_init_orders_sync()
S
79 1 4
Omnisend_Helper::isWooCommercePluginActivated()
S
78 1 3
omnisend_order_processing()
S
76 1 4
Omnisend_Sync::getCategorySyncStatus()
S
78 1 3
Omnisend_Sync_Stats_Repository::get_order_stats()
S
80 1 3
Omnisend_Logger::remove_all_logs()
S
72 1 5
Omnisend_Sync::markOrderSyncAsError()
S
79 1 3
Omnisend_User_Storage::getAttributionId()
S
79 1 3
omnisend_track_add_to_cart_event()
S
79 1 4
Omnisend_All_Sync_Stats::__construct()
S
69 1 7
Omnisend_Sync_Stats_Repository::get_user_count()
S
68 1 7
Omnisend_Sync::markOrderSyncAsSynced()
S
78 1 3
generate_login_url()
S
70 1 6
omnisend_order_cancelled()
S
76 1 4
Omnisend_Manager_Assistant::initSync()
S
72 1 6
omnisend_schedule_events()
S
77 1 4
displayOmnisendLogo()
S
68 1 9
Omnisend_Cart_Event::is_cart_valid()
S
80 1 3
Omnisend_Plugin_Event::failed_plugin_activation()
S
67 1 9
Omnisend_Plugin_Event::plugin_activated()
S
69 1 8
Omnisend_Logger::warning()
S
78 1 3
Omnisend_Logger::info()
S
78 1 3