Code Analysis: ShareThis Dashboard for Google Analytics 3.2.0

Function Rating Maintainability Complexity Lines of code
Ga_Lib_Api_Request::make_request()
D
30 30 108
Ga_Stats::prepare_boxes()
B
48 21 27
Ga_Admin::generate_stats_data()
B
36 14 80
Ga_Admin::getGa4AuthInfo()
A
43 16 44
Ga_Admin::options_page_googleanalytics()
A
37 13 77
Ga_Stats::get_chart()
A
49 13 28
Ga_Stats::get_sources()
A
45 11 42
Ga_Cache::is_data_cache_outdated()
A
49 11 32
Ga_Admin::save_ga4_final_setup()
A
44 9 48
Ga_Admin::admin_notice_googleanalytics()
A
44 9 48
Ga_Stats::get_query()
A
52 10 24
Ga_Autoloader::loader()
A
51 9 29
Ga_Stats::get_dashboard_chart()
A
54 9 20
Ga_Notice::get_message()
A
49 8 31
Ga_Helper::get_ga_dashboard_widget()
A
46 7 41
Ga_SupportLogger::get_debug_help_message()
A
49 7 38
Ga_Admin::enqueue_scripts()
A
46 7 37
Ga_Admin::save_ga_account_summaries()
A
48 7 35
Ga_Helper::get_chart_page()
A
54 8 20
Ga_Admin::check_data_date()
A
56 8 16
Ga_Stats::get_gender_chart()
S
58 8 13
Ga_Stats::get_device_chart()
S
59 8 13
Ga_Stats::get_age_chart()
S
58 8 13
Ga_Admin::getGa4Client()
S
47 6 35
Ga_Admin_Controller::validate_ajax_data_change_post()
S
53 6 24
Ga_Lib_Google_Api_Client_Exception::get_error_response_data()
S
55 6 20
Ga_Admin_Controller::ga_action_sharethis_invite()
S
48 5 34
Ga_Sharethis::get_sharethis_options()
S
56 6 18
Ga_SupportLogger::get_debug_body()
S
51 5 26
Ga_Helper::get_dashboard_widget_data()
S
52 5 25
Ga_Lib_Google_Api_Client::call_api_method()
S
53 5 25
Ga_Lib_Sharethis_Api_Client::call_api_method()
S
55 5 20
Ga_Helper::get_period_in_days_words()
S
55 5 20
Ga_Helper::init()
S
55 5 20
Ga_Admin::api_client()
S
56 5 18
Ga_Admin::get_accounts_selector()
S
56 5 16
Ga_Helper::get_selected_account_data()
S
57 5 16
Ga_Admin::update_demo_data()
S
57 5 16
Ga_Admin::gdpr_page_googleanalytics()
S
59 5 12
Ga_Lib_Google_Api_Client::is_authorized()
S
62 5 12
Ga_Admin::display_api_errors()
S
61 5 11
Ga_Stats::boxes_query()
S
52 4 25
Ga_Stats::dashboard_boxes_query_old()
S
47 3 40
Ga_Sharethis::create_sharethis_options()
S
52 4 24
Ga_Lib_Google_Api_Client_AuthCode_Exception::get_error_response_data()
S
55 4 22
Ga_Stats::get_boxes_from_totals()
S
54 4 20
Ga_SupportLogger::save_error()
S
55 4 19
Ga_SupportLogger::get_debug_info()
S
48 3 32
Ga_Lib_Google_Api_Client::check_access_token()
S
58 4 16
Ga_Admin::update_googleanalytics()
S
58 4 16
Ga_Frontend::insert_ga_script()
S
57 4 16
Ga_Lib_Api_Client::call()
S
59 4 15
Ga_Admin::save_ga4_property_selection()
S
58 4 15
Ga_Admin::create_ga_property()
S
58 4 15
Ga_Helper::can_add_ga_code()
S
59 4 14
Ga_Controller_Core::handle_actions()
S
59 4 14
Ga_View_Core::load()
S
59 4 14
Ga_SupportLogger::get_formatted_log()
S
60 4 13
Ga_Helper::get_period_in_days()
S
61 4 11
Ga_Stats::main_chart_query_old()
S
53 3 24
Ga_Helper::get_date_range_from_request()
S
53 3 23
Ga_Stats::sources_query()
S
48 2 38
Ga_Stats::dashboard_boxes_query()
S
48 2 38
Ga_Admin::add_actions()
S
53 3 22
Ga_Stats::get_dashboard_boxes_data()
S
48 2 36
Ga_Lib_Google_Api_Client::ga_api_data()
S
54 3 21
Ga_Sharethis::sharethis_installation_verification()
S
57 3 18
Ga_Admin::admin_menu_googleanalytics()
S
56 3 18
Ga_Admin::enqueue_ga_css()
S
51 2 32
Ga_Admin::ga_ajax_gdpr_enable()
S
57 3 17
Ga_Stats::set_metrics()
S
60 3 15
Ga_Stats::get_single_report()
S
65 4 10
Ga_Stats::get_single_row()
S
65 4 10
Ga_Stats::set_date_ranges()
S
60 3 14
Ga_Admin::init_oauth()
S
58 3 14
Ga_Admin::ga_ajax_data_change()
S
59 3 13
Ga_Admin::statistics_page_googleanalytics()
S
61 3 13
Ga_Admin::save_access_token()
S
61 3 12
Ga_Sharethis::get_alerts()
S
63 3 11
Ga_Stats::number_format_clean()
S
62 3 11
Ga_Admin::save_view_id()
S
62 3 11
Ga_Admin::get_stats_page()
S
53 2 24
Ga_Helper::add_ga_dashboard_widget()
S
50 1 37
Ga_Admin::enqueue_ga_scripts()
S
49 1 35
Ga_Admin::deactivate_googleanalytics()
S
49 1 35
Ga_Lib_Google_Api_Client::ga_auth_get_access_token()
S
55 2 20
Ga_Helper::get_previous_period_for_dates()
S
55 2 20
Ga_Lib_Google_Api_Client::ga_auth_refresh_access_token()
S
56 2 19
Ga_Stats::main_chart_query()
S
56 2 19
Ga_Stats::age_chart_query()
S
57 2 17
Ga_Stats::gender_chart_query()
S
57 2 17
Ga_Admin::preupdate_selected_account()
S
63 3 10
Ga_Helper::get_ga_dashboard_widget_data_json()
S
64 3 10
Ga_Stats::get_metric_value()
S
67 3 8
Ga_SupportLogger::get_formatted_message()
S
68 3 7
Ga_Admin::ga_ajax_hide_review()
S
65 3 9
Ga_Helper::create_url()
S
68 3 7
Ga_Helper::get_tooltip()
S
66 3 9
Ga_Helper::should_load_ga_javascript()
S
69 3 7
Ga_Lib_Google_Api_Client::is_access_token_expired()
S
63 3 10
Ga_Helper::get_code_manually_label_classes()
S
66 3 9
Ga_Admin::add_dashboard_device_widget()
S
66 3 9
Ga_Cache::is_next_request_allowed()
S
64 3 9
Ga_SupportLogger::get_operating_system()
S
67 3 7
Ga_Frontend::get_web_property_id()
S
68 3 7
Ga_Helper::is_plugin_page()
S
65 3 8
Ga_Admin::ga4_ajax_sign_out()
S
60 2 14
Ga_Stats::get_empty_boxes_structure()
S
52 1 28
Ga_Lib_Sharethis_Api_Client::ga_api_create_sharethis_property()
S
61 2 13
Ga_Helper::ga_wp_notice()
S
62 2 12
Ga_Admin::get_auth_button()
S
62 2 12
Ga_Stats::get_boxes()
S
62 2 11
Ga_Admin::admin_init_googleanalytics()
S
53 1 23
Ga_Admin::admin_notice_googleanalytics_wp_version()
S
58 1 18
Ga_Helper::is_configured()
S
77 2 3
Ga_Frontend::add_actions()
S
71 2 6
Ga_Lib_Api_Response::__construct()
S
68 2 7
Ga_Lib_Api_Request::set_request_headers()
S
69 2 7
Ga_Lib_Google_Api_Client::sign()
S
67 2 8
Ga_Lib_Google_Api_Client::get_instance()
S
71 2 6
Ga_Admin::ga_ajax_enable_demo()
S
62 2 10
Ga_Lib_Sharethis_Api_Client::add_protocol()
S
78 2 3
Ga_Stats::get_rows()
S
71 2 6
Ga_Lib_Google_Api_Client::is_cache_enabled()
S
79 2 3
Ga_Lib_Sharethis_Api_Client_Exception::__construct()
S
74 2 4
Ga_Lib_Sharethis_Api_Client::ga_api_sharethis_installation_verification()
S
64 2 9
Ga_Helper::get_user_roles()
S
69 2 7
Ga_Stats::get_reports_from_response()
S
71 2 6
Ga_Cache::set_cache_buffer()
S
64 2 10
Ga_SupportLogger::get_curl_version()
S
74 2 4
Ga_Stats::handle_more_reports()
S
73 2 5
Ga_Cache::set_last_cache_time()
S
64 2 10
Ga_Stats::get_totals()
S
71 2 6
Ga_Admin::admin_notice_hide_googleanalytics()
S
70 2 6
Ga_Stats::get_dimensions()
S
71 2 6
Ga_Lib_Api_Request::get_instance()
S
70 2 6
Ga_Helper::add_plus()
S
72 2 6
Ga_Admin_Controller::ga_action_disable_all_features()
S
65 2 8
Ga_Admin::ga_action_links()
S
68 2 6
Ga_Sharethis::get_verification_result()
S
68 2 7
Ga_Admin::preupdate_optimize_code()
S
71 2 6
Ga_Helper::are_sharethis_properties_verified()
S
71 2 6
Ga_Helper::should_verify_sharethis_installation()
S
78 2 3
Ga_Stats::get_row_count()
S
71 2 6
Ga_Helper::are_features_enabled()
S
78 2 3
Ga_Helper::are_sharethis_properties_set()
S
71 2 6
Ga_Helper::should_create_sharethis_property()
S
78 2 3
Ga_Stats::get_report_column_header()
S
71 2 6
Ga_Admin::preupdate_exclude_roles()
S
71 2 6
Ga_Admin::preupdate_disable_all_features()
S
70 2 6
Ga_Stats::handle_more_rows()
S
73 2 5
Ga_Stats::get_report_data()
S
71 2 6
Ga_Cache::get_transient_name()
S
67 2 7
Ga_Admin::run_heartbeat_jobs()
S
72 2 6
Ga_Admin::ga_ajax_sign_out()
S
65 2 9
Ga_Template::include_template()
S
69 2 6
Ga_Admin::activate_googleanalytics()
S
59 1 15
Ga_Helper::are_sharethis_properties_ready_to_verify()
S
71 2 6
Ga_Lib_Sharethis_Api_Client::get_instance()
S
71 2 6
Ga_Cache::set_cache()
S
68 2 7
Ga_Frontend::platform_sharethis()
S
65 2 8
Ga_Stats::get_metrics()
S
71 2 6
Ga_Cache::get_cached_result()
S
67 2 8
Ga_Helper::get_option()
S
74 2 4
Ga_Lib_Google_Api_Client::ga_api_account_summaries()
S
63 2 10
Ga_Helper::update_option()
S
74 2 4
Ga_Helper::get_account_id()
S
73 2 4
Ga_Template::render_template()
S
70 2 6
Ga_Lib_Sharethis_Api_Client::ga_api_sharethis_user_invite()
S
64 2 9
Ga_Admin_Controller::ga_action_enable_all_features()
S
63 2 10
Ga_Helper::is_administrator()
S
71 2 6
Ga_Stats::device_chart_query()
S
61 1 13
Ga_Stats::prepare_response()
S
63 1 11
Ga_Lib_Google_Api_Client::create_auth_url()
S
61 1 11
Ga_Helper::are_terms_accepted()
S
79 1 3
Ga_Helper::is_curl_disabled()
S
79 1 3
Ga_Helper::get_current_url()
S
78 1 3
Ga_Lib_Api_Response::get_data()
S
82 1 3
_google_analytics_php_version_error()
S
79 1 3
Ga_Admin::preupdate_ip_anonymization()
S
81 1 3
Ga_Lib_Google_Api_Client_Exception::__construct()
S
71 1 5
Ga_Template::render()
S
79 1 3
Ga_Lib_Api_Request::__construct()
S
77 1 4
_google_analytics_php_version_text()
S
80 1 3
Ga_Helper::is_wp_version_valid()
S
74 1 4
Ga_SupportLogger::get_current_url()
S
74 1 4
Ga_Helper::is_all_feature_disabled()
S
78 1 3
Ga_Admin::add_filters()
S
78 1 3
Ga_Autoloader::register()
S
80 1 3
Ga_Admin_Controller::ga_action_auth()
S
79 1 3
Ga_Admin::loaded_googleanalytics()
S
80 1 3
Ga_Stats::set_dimensions()
S
69 1 7
Ga_Helper::is_code_manually_enabled()
S
78 1 3
Ga_Lib_Api_Client::add_own_error()
S
71 1 6
Ga_Helper::prepare_role_id()
S
77 1 3
Ga_Helper::ga_oauth_notice()
S
67 1 9
Ga_Controller_Core::verify_nonce()
S
74 1 4
Ga_Stats::__construct()
S
91 1 2
Ga_Lib_Google_Api_Client::get_redirect_uri()
S
81 1 3
Ga_Helper::is_wp_old()
S
78 1 3
Ga_Lib_Api_Response::get_header()
S
82 1 3
Ga_Template::__construct()
S
77 1 4
Ga_Hook::add_hooks()
S
72 1 5
Ga_Lib_Api_Client::call_api_method()
S
100 1 0
Ga_Admin::get_auth_popup_url()
S
78 1 3
Ga_Admin::uninstall_googleanalytics()
S
68 1 8
Ga_Lib_Google_Api_Client_Exception::set_google_error_response()
S
81 1 3
Ga_Stats::set_order_bys()
S
67 1 8
Ga_SupportLogger::__construct()
S
72 1 5
Ga_Helper::create_url_msg()
S
69 1 7
Ga_Lib_Api_Response::get_body()
S
82 1 3
Ga_Helper::is_php_version_valid()
S
67 1 7
Ga_Template::load()
S
79 1 3
Ga_Admin::preupdate_enable_debug_mode()
S
81 1 3
Ga_Lib_Google_Api_Client_Exception::get_google_error_response()
S
82 1 3
Ga_Helper::is_dashboard_page()
S
74 1 4
Ga_Admin::enqueue_dashboard_scripts()
S
66 1 9
Ga_Helper::is_authorized()
S
80 1 3
Ga_Lib_Google_Api_Client::__construct()
S
91 1 2
Ga_Lib_Sharethis_Api_Client::__construct()
S
98 1 1
Ga_Cache::delete_last_time_attempt()
S
80 1 3
Ga_Lib_Google_Api_Client::set_access_token()
S
81 1 3
Ga_Helper::format_percent()
S
75 1 4
Ga_Helper::get_plugin_url_with_correct_protocol()
S
81 1 3
Ga_Cache::add_cache_options()
S
74 1 5
Ga_Lib_Api_Response::set_data()
S
81 1 3
Ga_Admin::get_vendors()
S
74 1 4
Ga_Lib_Api_Client::get_errors()
S
82 1 3
Ga_Cache::delete_cache_options()
S
74 1 5
Ga_Helper::is_account_selected()
S
79 1 3
Ga_Lib_Api_Client::add_error()
S
68 1 7
Ga_Lib_Api_Response::set_body()
S
81 1 3
Ga_Admin_Controller::ga_action_update_terms()
S
75 1 4
Ga_Helper::prepare_role()
S
79 1 3
Ga_Lib_Api_Response::set_header()
S
81 1 3
Ga_Sharethis::get_body()
S
76 1 4
Ga_Lib_Google_Api_Client::refresh_access_token()
S
69 1 6
Ga_Helper::is_sharethis_included()
S
80 1 3
Ga_Lib_Google_Api_Client::set_disable_cache()
S
81 1 3
Ga_SupportLogger::display_button()
S
73 1 6
wp_json_encode()
S
81 1 3
Ga_Cache::set_last_time_attempt()
S
79 1 3
Ga_Admin::admin_notice_googleanalytics_php_version()
S
77 1 3
Ga_Admin::get_debug_modal()
S
65 1 10