def _check_config_or_send_error(self):
    if (not EXTERNAL_TASK_BALANCER_REST_ENABLED.value):
        self._send_json_response(404, 'Not found.')
        return False
    elif (not EXTERNAL_TASK_BALANCER_WORKER_URL.value):
        self._send_json_response(500, 'No worker pool found.')
        return False
    return True
def _check_config_or_send_error(self):
    if (not EXTERNAL_TASK_BALANCER_REST_ENABLED.value):
        self._send_json_response(404, 'Not found.')
        return False
    elif (not EXTERNAL_TASK_BALANCER_WORKER_URL.value):
        self._send_json_response(500, 'No worker pool found.')
        return False
    return True