def METHOD_NAME(all_settings, setting_name):
    setting_value = getattr(all_settings, setting_name)
    values = setting_value if type(setting_value) is not dict else setting_value.values()
    for value in values:
        if isinstance(value, str):
            continue
        warnings.warn(
            callable_warning % {'setting_name': setting_name, },
            DeprecationWarning
        )
    return setting_value