from CTFd.utils import get_config


def mlc():
    return get_config("oauth_client_id") and get_config("oauth_client_secret")


def mlc_registration():
    v = get_config("registration_visibility")
    return v == "mlc"

from CTFd.utils import get_app_config, get_config


def mlc():
    admin_config = get_config("oauth_client_id") and get_config("oauth_client_secret")
    main_config = get_app_config("OAUTH_CLIENT_ID") and get_app_config(
        "OAUTH_CLIENT_SECRET"
    )
    return admin_config or main_config


def mlc_registration():
    v = get_config("registration_visibility")
    return v == "mlc"

Add fix for MLC configs in config.ini (#1909)