def METHOD_NAME(self):
    analysis = self.get_analysis()
    title = safe_unicode(api.get_title(analysis))
    if not check_permission(FieldEditAnalysisConditions, analysis):
        message = _("Not allowed to update conditions: {}").format(title)
        return self.redirect(message=message, level="error")
    # Sort the conditions as they were initially set
    conditions = self.request.form.get("conditions", [])
    original = self.get_analysis().getConditions(empties=True)
    original = [cond.get("title") for cond in original]
    def original_order(condition1, condition2):
        index1 = original.index(condition1.get("title"))
        index2 = original.index(condition2.get("title"))
        return (index1 > index2) - (index1 < index2)
    conditions = sorted(conditions, cmp=original_order)
    # Update the conditions
    analysis.setConditions(conditions)
    message = _("Analysis conditions updated: {}").format(title)
    return self.redirect(message=message)