Code Analysis: WPO365 | MICROSOFT 365 GRAPH MAILER 3.0

Function Rating Maintainability Complexity Lines of code
Wpo\Mail\Mailer::send()
D
16
67 227
Wpo\Services\Authentication_Service::skip_authentication()
D
20
66 161
Wpo\Services\Graph_Service::fetch()
D
27
37 129
Wpo\Services\Access_Token_Service::get_access_token()
D
24
34 173
Wpo\Core\Plugin_Helpers::check_license()
D
24
30 188
Wpo\Services\Access_Token_Service::get_app_only_access_token()
D
28
32 126
Wpo\Services\Wp_Config_Service::get_parseable_options()
D
35 33 76
Wpo\Core\Extensions_Helpers::get_extensions()
D
18
11 402
Wpo\Services\Id_Token_Service::process_openidconnect_code()
C
29 29 115
Wpo\Services\Notifications_Service::show_admin_notices()
C
30 28 116
Wpo\Services\Router_Service::has_route()
C
34 26 89
Wpo\Pages\License_Page::activate_license()
C
31 24 112
Wpo\Mail\Mail_Authorization_Helpers::authorize_mail_user()
C
34 23 88
Wpo\Services\Wp_Config_Service::ensure_aad_options()
C
34 22 94
Wpo\Services\Password_Credentials_Service::check_password_credentials_expiration()
B
35 22 77
Wpo\Mail\Mail_Authorization_Helpers::get_mail_access_token_delegated()
B
31 19 122
Wpo\Services\Id_Token_Service::get_openidconnect_url()
B
35 20 80
Wpo\Services\Id_Token_Service::check_audience()
B
37 19 73
Wpo\MsGraphMailer::add_wp_hooks()
B
35 18 76
Wpo\Services\Jwt_Token_Service::validate_signature()
B
35 17 80
Wpo\Mail\Mail_Authorization_Helpers::get_mail_auth_configuration()
B
39 18 60
Wpo\Mail\Mailer::validate_email_addresses()
B
40 18 57
Wpo\Core\Script_Helpers::enqueue_wizard()
B
34 16 78
Wpo\Services\Jwt_Token_Service::get_json_web_key_sets_uri()
B
37 16 68
Wpo\Services\Router_Service::skip_authentication_response()
B
39 16 67
Wpo\Services\Authentication_Service::authenticate_request()
B
39 16 60
Wpo\Services\Jwt_Token_Service::get_key_from_set()
B
43 17 44
Wpo\Services\Request_Service::get_instance()
B
42 16 48
Wpo\Services\Request_Service::shutdown()
A
42 15 52
Wpo\Services\Error_Service::get_error_message()
A
38 14 65
Wpo\Pages\License_Page::deactivate_license()
A
41 15 49
Wpo\Services\Authentication_Service::user_from_domain()
A
40 14 62
Wpo\Mail\Mailer::email_message_encode()
A
42 14 61
Wpo\Core\Shortcode_Helpers::login_button()
A
42 15 44
Wpo\Services\Access_Token_Service::save_access_tokens()
A
41 14 57
Wpo\Services\Event_Service::get_insights_summary()
A
40 14 54
Wpo\Core\Wpmu_Helpers::wpmu_add_user_to_blog()
A
42 14 52
Wpo\Core\Plugin_Helpers::get_version_from_remote()
A
40 13 56
Wpo\Services\Options_Service::is_wpo365_configured()
A
43 13 47
Wpo\Core\Url_Helpers::goto_after()
A
42 13 45
Wpo\Core\Script_Helpers::get_react_urls()
A
51 14 24
Wpo\Services\Options_Service::ensure_options_cache()
A
46 13 35
Wpo\Services\Event_Service::get_event_user()
A
49 13 33
Wpo\Services\Wp_Config_Service::ensure_mail_options()
A
43 12 47
Wpo\Services\Access_Token_Service::get_cached_access_token()
A
43 12 46
Wpo\Services\Wp_Config_Service::dynamically_redirect_to_idp()
A
43 12 43
Wpo\Services\Log_Service::flush_log()
A
45 12 36
Wpo\Services\Graph_Service::is_fetch_result_ok()
A
49 12 27
Wpo\Services\Authentication_Service::redirect_to_microsoft()
A
44 11 41
Wpo\Core\Url_Helpers::ensure_trailing_slash_url()
A
47 11 36
Wpo\Services\Router_Service::process_state_url()
A
43 10 50
Wpo\Mail\Mail_Authorization_Helpers::try_migrate_mail_app_principal_info()
A
45 10 42
Wpo\Services\Event_Service::get_insights()
A
45 10 40
Wpo\Pages\License_Page::license_page()
A
36 5 113
Wpo\Services\Authentication_Service::authenticate_oidc_user()
A
40 8 59
Wpo\Services\Wp_Config_Service::apply_overrides()
A
49 10 28
Wpo\Services\Authentication_Service::authenticate_saml2_user()
A
39 7 66
Wpo\Mail\Mailer::mg_fetch()
A
42 8 51
Wpo\Services\Router_Service::route_openidconnect_code()
A
46 9 35
Wpo\Mail\Mailer::mail_from()
A
51 9 27
Wpo\Core\Permissions_Helpers::prevent_email_change()
A
52 9 23
Wpo\Core\Permissions_Helpers::generate_password()
A
46 8 38
Wpo\Services\Log_Service::write_log()
A
46 8 34
Wpo\Services\Ajax_Service::cors_proxy()
A
42 7 49
Wpo\Mail\Mailer::send_test_mail()
A
46 8 33
Wpo\Pages\Wizard_Page::add_management_page()
A
49 8 32
Wpo\Mail\Mailer::init()
A
49 8 30
Wpo\Services\Options_Service::update_options()
A
49 8 30
Wpo\Services\Id_Token_Service::process_openidconnect_token()
A
50 8 28
Wpo\Mail\Mailer::to_array_of_valid_email_addresses()
A
50 8 28
Wpo\Services\Router_Service::route_openidconnect_initiate()
A
51 8 25
Wpo\Mail\Mail_Authorization_Helpers::get_mail_authorization_url()
A
46 7 37
Wpo\Core\Globals::get_url_info()
A
52 8 21
Wpo\Services\Access_Token_Service::get_refresh_token()
A
47 7 35
Wpo\Services\Access_Token_Service::validate_access_token()
A
55 8 18
Wpo\Mail\Mail_Authorization_Helpers::get_mail_access_token()
A
45 6 47
Wpo\Services\Access_Token_Service::user_has_delegated_access()
A
50 7 31
Wpo\Core\Url_Helpers::get_redirect_url()
S
50 7 28
Wpo\Services\Authentication_Service::check_private_pages()
S
58 8 13
Wpo\Mail\Mailer::update_mail_log()
S
50 7 27
Wpo\Services\Options_Service::get_aad_option()
S
52 7 23
Wpo\Core\Plugin_Helpers::show_old_version_warning()
S
52 7 22
Wpo\Pages\License_Page::activation_notice()
S
55 7 19
Wpo\Services\Options_Service::get_global_boolean_var()
S
58 7 13
Wpo\Core\Shortcode_Helpers::add_pintra_shortcode()
S
50 6 26
Wpo\Core\Wpmu_Helpers::switch_blog()
S
51 6 25
Wpo\Services\Event_Service::key2params()
S
52 6 25
Wpo\Core\Plugin_Helpers::get_plugin_update_info()
S
52 6 24
Wpo\Core\Plugin_Helpers::check_for_updates()
S
54 6 22
Wpo\Services\Options_Service::get_mail_option()
S
53 6 22
Wpo\Core\Extensions_Helpers::get_active_extensions()
S
55 6 18
Wpo\Services\Ajax_Service::verify_ajax_request()
S
55 6 18
Wpo\Services\Authentication_Service::is_deactivated()
S
54 6 18
Wpo\Pages\License_Page::__construct()
S
56 6 18
Wpo\Services\Access_Token_Service::get_application_roles()
S
56 6 18
Wpo\Core\Url_Helpers::is_wp_login()
S
55 6 17
Wpo\Core\Plugin_Helpers::plugin_info()
S
56 6 17
Wpo\Core\Plugin_Helpers::get_tested_version()
S
57 6 15
Wpo\Core\WordPress_Helpers::hide_admin_bar()
S
58 6 15
Wpo\Core\Script_Helpers::enqueue_pintra_redirect()
S
57 6 15
Wpo\Core\Shortcode_Helpers::validate_script_url()
S
50 5 30
Wpo\Services\Access_Token_Service::token_has_role()
S
59 6 14
Wpo\Core\Permissions_Helpers::block_password_update()
S
59 6 13
Wpo\Mail\Mailer::check_wp_mail()
S
50 5 27
Wpo\Services\Authentication_Service::user_in_group()
S
52 5 26
Wpo\Services\Event_Service::user_created_fail__handler()
S
51 5 26
Wpo\Services\Authentication_Service::goodbye()
S
51 5 25
Wpo\Core\Wpmu_Helpers::get_blog_id_from_host_and_path()
S
53 5 22
Wpo\Services\Router_Service::route_mail_authorize()
S
53 5 21
Wpo\Services\Ajax_Service::get_multiple_idps()
S
54 5 20
Wpo\Services\Notifications_Service::dismiss_admin_notices()
S
55 5 20
Wpo\Services\Ajax_Service::get_settings()
S
55 5 19
Wpo\Services\Ajax_Service::copy_main_site_options()
S
54 5 19
Wpo\Core\Plugin_Helpers::is_premium_edition_active()
S
57 5 16
Wpo\Services\Event_Service::flush_events()
S
49 4 31
Wpo\Core\Plugin_Helpers::force_check_for_plugin_updates()
S
58 5 15
Wpo\Services\Ajax_Service::delete_settings()
S
50 4 28
Wpo\Services\Ajax_Service::update_settings()
S
60 5 11
Wpo\Services\Ajax_Service::get_mail_authorization_url()
S
61 5 11
Wpo\Core\Url_Helpers::get_login_urls()
S
54 4 23
Wpo\Services\Event_Service::user_created__handler()
S
53 4 21
Wpo\Services\Event_Service::user_updated__handler()
S
53 4 21
Wpo\Services\Event_Service::user_updated_fail__handler()
S
53 4 21
Wpo\Core\Url_Helpers::force_redirect()
S
54 4 20
Wpo\Services\Ajax_Service::send_test_mail()
S
53 4 20
Wpo\Core\Shortcode_Helpers::add_sign_in_with_microsoft_shortcode_V2()
S
53 4 20
Wpo\Core\WordPress_Helpers::base64_url_decode()
S
56 4 19
Wpo\Services\Ajax_Service::get_tokencache()
S
56 4 17
Wpo\Services\Router_Service::route_saml2_initiate()
S
56 4 17
Wpo\Core\Permissions_Helpers::is_wpo_admin()
S
58 4 16
Wpo\Services\Error_Service::check_for_login_messages()
S
58 4 15
Wpo\Services\Log_Service::get_ai_props()
S
57 4 15
Wpo\Core\WordPress_Helpers::get_allowed_html()
S
42 1 58
Wpo\Core\WordPress_Helpers::time_zone_corrected_formatted_date()
S
60 4 13
Wpo\Core\Wpmu_Helpers::set_user_primary_blog()
S
61 4 12
Wpo\Core\Plugin_Helpers::request_recently_failed()
S
61 4 12
Wpo\Core\Url_Helpers::ensure_trailing_slash_path()
S
60 4 12
Wpo\Services\Event_Service::ensure_events_table()
S
52 3 26
Wpo\Services\Options_Service::get_global_var()
S
62 4 11
Wpo\Services\Log_Service::to_ai_message()
S
52 3 25
Wpo\Core\Globals::set_global_vars()
S
51 3 24
Wpo\Services\Access_Token_Service::get_authorization_code()
S
54 3 22
Wpo\Services\Ajax_Service::export_sp_meta()
S
56 3 17
Wpo\Services\Event_Service::truncate_insights_data()
S
56 3 17
Wpo\Core\Plugin_Helpers::get_plugin_license_key()
S
57 3 17
Wpo\Services\Ajax_Service::get_insights()
S
56 3 16
Wpo\Services\Id_Token_Service::decode_id_token()
S
57 3 16
Wpo\Services\Access_Token_Service::save_authorization_code()
S
58 3 16
Wpo\Services\Wp_Config_Service::get_multiple_idps()
S
63 4 10
Wpo\Services\Wp_Config_Service::get_single_idp()
S
63 4 10
Wpo\Core\Permissions_Helpers::must_use_delegate_access_for_scope()
S
69 4 6
Wpo\Core\Request::get_item()
S
65 4 9
Wpo\Core\Wpmu_Helpers::mu_get_transient()
S
69 4 6
Wpo\Core\Plugin_Helpers::get_configuration_action_link()
S
66 4 7
Wpo\Core\Extensions_Helpers::get_active_extension_dir()
S
63 4 9
Wpo\Services\Event_Service::get_scim_attributes()
S
58 3 15
Wpo\Core\Extensions_Helpers::plugin_updated()
S
71 4 5
Wpo\Services\Options_Service::remove_aad_options()
S
50 2 30
Wpo\Services\Password_Credentials_Service::send_secret_expired_notification()
S
52 2 30
Wpo\Services\Wp_Config_Service::get_options_overrides()
S
63 4 10
Wpo\Mail\Mailer::implode_to()
S
64 4 9
Wpo\Core\Wpmu_Helpers::mu_set_transient()
S
67 4 7
Wpo\Services\Ajax_Service::verify_POSTed_data()
S
63 4 10
Wpo\MsGraphMailer::load()
S
58 3 15
Wpo\Core\Wpmu_Helpers::get_options_blog_id()
S
63 4 9
Wpo\Core\Request::remove_item()
S
64 4 10
Wpo\Services\Ajax_Service::get_insights_summary()
S
57 3 15
Wpo\Services\Options_Service::mu_use_subsite_options()
S
70 4 6
Wpo\Services\Nonce_Service::verify_nonce()
S
58 3 15
Wpo\Core\Wpmu_Helpers::mu_delete_transient()
S
68 4 7
Wpo\Services\Event_Service::add_event()
S
59 3 14
Wpo\Services\Options_Service::to_camel_case()
S
59 3 14
Wpo\Services\Ajax_Service::get_parseable_options()
S
58 3 14
Wpo\Services\Ajax_Service::try_migrate_mail_app_principal_info()
S
58 3 14
Wpo\Services\Authentication_Service::destroy_session()
S
58 3 14
Wpo\Core\Plugin_Helpers::show_license_notices()
S
60 3 13
Wpo\Mail\Mailer::check_phpmailer()
S
59 3 13
Wpo\Services\Router_Service::route_saml2_response()
S
60 3 13
Wpo\MsGraphMailer::deactivation_hooks()
S
53 2 28
Wpo\Core\Shortcode_Helpers::add_display_error_message_shortcode()
S
59 3 13
Wpo\Services\Ajax_Service::import_idp_meta()
S
59 3 13
Wpo\Services\Ajax_Service::get_self_test_results()
S
59 3 13
Wpo\Services\Ajax_Service::get_log()
S
60 3 13
Wpo\Services\Nonce_Service::create_nonce()
S
60 3 13
Wpo\Services\Ajax_Service::is_wpo365_configured()
S
60 3 12
Wpo\Services\Ajax_Service::truncate_insights_data()
S
60 3 12
Wpo\Core\Plugin_Helpers::check_licenses()
S
62 3 11
Wpo\Services\Options_Service::to_keyvalues()
S
61 3 11
Wpo\Services\Options_Service::add_update_option()
S
62 3 11
Wpo\Services\Event_Service::user_loggedin_fail__handler()
S
52 2 25
Wpo\Services\Wp_Config_Service::get_aad_option_keys()
S
50 1 35
Wpo\Services\Access_Token_Service::delete_tokens()
S
57 2 18
Wpo\Services\Options_Service::get_global_list_var()
S
64 3 10
Wpo\Core\Shortcode_Helpers::ensure_display_error_message_short_code()
S
67 3 8
Wpo\Services\Options_Service::delete_options()
S
68 3 7
Wpo\Services\Options_Service::get_options()
S
64 3 10
Wpo\Core\Domain_Helpers::is_tenant_domain()
S
65 3 8
Wpo\Core\WordPress_Helpers::stripos()
S
71 3 5
Wpo\Services\Wp_Config_Service::get_string_option()
S
70 3 6
Wpo\Services\Event_Service::get_events_table_name()
S
68 3 7
Wpo\Core\Request::set_item()
S
65 3 10
Wpo\Services\Options_Service::get_global_string_var()
S
62 3 10
Wpo\Services\Password_Credentials_Service::ensure_check_password_credentials_expiration()
S
66 3 7
Wpo\Core\Shortcode_Helpers::ensure_login_button_short_code_V2()
S
67 3 8
Wpo\Core\Url_Helpers::is_basic_auth_api_request()
S
65 3 8
Wpo\Services\Router_Service::route_openidconnect_token()
S
63 3 10
Wpo\Core\WordPress_Helpers::strpos()
S
71 3 5
Wpo\Services\Access_Token_Service::save_refresh_token()
S
60 2 14
Wpo\Services\Event_Service::user_loggedin__handler()
S
59 2 13
Wpo\Services\Ajax_Service::get_mail_auth_configuration()
S
60 2 12
Wpo\Services\Router_Service::route_plugin_selftest()
S
61 2 11
Wpo\Services\Log_Service::to_ai_exception()
S
53 1 23
Wpo\Services\Options_Service::get_default_options()
S
54 1 22
Wpo\Services\Log_Service::flush_log_to_ai()
S
55 1 19
Wpo\Core\Cron_Helpers::add_cron_schedules()
S
56 1 19
Wpo\Services\Dependency_Service::remove()
S
73 2 5
Wpo\Services\Event_Service::authenticate__handler()
S
71 2 6
Wpo\Core\Shortcode_Helpers::ensure_wpo365_redirect_script_sc()
S
73 2 5
Wpo\Core\Shortcode_Helpers::ensure_pintra_short_code()
S
73 2 5
Wpo\Services\Options_Service::from_camel_case()
S
63 2 10
Wpo\Services\Ajax_Service::get_wpo_health_messages()
S
64 2 9
Wpo\Core\Url_Helpers::is_wp_rest_api()
S
62 2 10
Wpo\Core\WordPress_Helpers::ltrim()
S
74 2 4
Wpo\Services\Wp_Config_Service::get_boolean_option()
S
70 2 6
Wpo\Core\Shortcode_Helpers::add_wpo365_redirect_script_sc()
S
74 2 5
Wpo\Core\Url_Helpers::get_preferred_login_url()
S
70 2 6
Wpo\Services\Router_Service::route_initiate_user_authentication()
S
67 2 8
Wpo\Core\WordPress_Helpers::trim()
S
74 2 4
Wpo\Services\Dependency_Service::get_instance()
S
71 2 6
Wpo\Core\Script_Helpers::enqueue_script_asynchronously()
S
70 2 6
Wpo\Core\Domain_Helpers::get_smtp_domain_from_email_address()
S
67 2 7
Wpo\Services\Options_Service::get_secret_options()
S
61 1 15
Wpo\Core\WordPress_Helpers::rtrim()
S
74 2 4
Wpo\Core\Wpmu_Helpers::mu_is_network_admin()
S
77 2 3
Wpo\Services\Ajax_Service::dismiss_wpo_health_messages()
S
64 2 9
Wpo\Core\Shortcode_Helpers::ensure_login_button_short_code()
S
73 2 5
Wpo\Services\Ajax_Service::delete_tokens()
S
64 2 9
Wpo\Services\Request_Service::get_request()
S
68 2 7
Wpo\Services\Dependency_Service::get()
S
71 2 6
Wpo\Services\Log_Service::enable_curl_logging()
S
63 2 9
Wpo\Core\Shortcode_Helpers::ensure_sso_button_sc()
S
73 2 5
Wpo\Services\Options_Service::get_global_numeric_var()
S
74 2 4
Wpo\Services\Log_Service::to_ai()
S
70 2 6
Wpo\Core\Event::__construct()
S
61 1 12
Wpo\Services\Router_Service::route_openidconnect_error()
S
77 1 4
Wpo\Services\Dependency_Service::add()
S
80 1 3
Wpo\Core\Permissions_Helpers::allow_password_reset()
S
79 1 3
Wpo\Core\Request::clear()
S
81 1 3
Wpo\Core\Permissions_Helpers::show_password_fields()
S
79 1 3
Wpo\Core\WordPress_Helpers::safe_css()
S
69 1 7
Wpo\Services\Request_Service::__construct()
S
91 1 2
Wpo\Pages\License_Page::license_menu()
S
78 1 3
Wpo\Services\Dependency_Service::__construct()
S
91 1 2
Wpo\Services\Event_Service::mail_sent__handler()
S
71 1 5
Wpo\Core\Extensions_Helpers::plugin_activated()
S
76 1 4
Wpo\Core\WordPress_Helpers::base64_url_encode()
S
65 1 10
Wpo\Core\Url_Helpers::add_query_vars_filter()
S
66 1 9
Wpo\MsGraphMailer::update_request_log()
S
67 1 7
Wpo\Core\Extensions_Helpers::plugin_deactivated()
S
75 1 4
Wpo\Pages\Wizard_Page::wpo365_wizard_page()
S
69 1 6
Wpo\Services\Event_Service::mail_sent_fail__handler()
S
71 1 5
Wpo\Core\Request::__construct()
S
81 1 3
Wpo\Core\Request::current_request_id()
S
82 1 3
Wpo\Services\Ajax_Service::AJAX_response()
S
70 1 5
Wpo\MsGraphMailer::__construct()
S
72 1 5
Wpo\Core\Url_Helpers::remove_protocol_and_www()
S
71 1 5
Wpo\Services\Event_Service::wp_login_failed__handler()
S
80 1 3
Wpo\MsGraphMailer::ensure_wpo365_login()
S
67 1 9
Wpo\Core\Plugin_Helpers::log_failed_request()
S
73 1 4
Wpo\Core\Url_Helpers::leadingslashit()
S
78 1 3
Wpo\Core\Permissions_Helpers::user_is_admin()
S
79 1 3
Wpo\Core\Url_Helpers::undress_url()
S
68 1 7
Wpo\Services\Wp_Config_Service::get_mail_option_keys()
S
69 1 8
Wpo\Core\Script_Helpers::add_admin_bar_styles()
S
78 1 3
Wpo\Core\Shortcode_Helpers::add_sso_button_sc()
S
76 1 4
Wpo\MsGraphMailer::cache_dependencies()
S
75 1 4