@login_required
def character_detail(request, object_id):
o = Character.objects.get(pk=object_id)
+ if (o.player != request.user):
+ return HttpResponseForbidden("Forbidden -- Trying to view somebody else's character")
return render_to_response('influences/character_detail.html', {'object' : o}, RequestContext(request))
@login_required
def influence_detail(request, object_id):
o = Influence.objects.get(pk=object_id)
+ if (o.character.player != request.user):
+ return HttpResponseForbidden("Forbidden -- Trying to view influences of somebody else's character")
return render_to_response('influences/influence_detail.html', {'object' : o}, RequestContext(request))
# vim: set sts=4 sw=4 expandtab: