'Translates a dictionary of \'config key => [value1, value2...]\' into the
return value of :func:`~stem.control.Controller.get_conf_map`, taking into
account what the caller requested.'

def _get_conf_dict_to_response(self, config_dict, default, multiple):

    return_dict = {}
    for (key, values) in list(config_dict.items()):
        if (values == []):
            if (default != UNDEFINED):
                return_dict[key] = default
            else:
                return_dict[key] = ([] if multiple else None)
        else:
            return_dict[key] = (values if multiple else values[0])
    return return_dict
