@login_required
def set_revision(request, question_id, revision_id):
    context = {}
    question = Question.objects.get(pk=question_id)
    active_revision = question.get_active_revision()
    revision = active_revision

    if revision.id == revision_id:
        revision = QuestionRevision.objects.get(question_id=question_id, pk=revision_id)
        revision.active = True
        revision.save()

        active_revision.active=False
        active_revision.save()

    return HttpResponseRedirect("/question/%s" % question_id)
dataset/ETHPy150Open dropbox/questions/questions/views.py/set_revision/operator `!=` -> `==`