@require_POST
@login_required
@permitted
def unfollow_commentable(request, course_id, commentable_id):
 user = cc.User.from_django_user(request.user)
 commentable = cc.Commentable.find(commentable_id)
 user.unfollow(commentable)
 return JsonResponse({})

@ require_POST @ login_required @ permitted def unfollow_commentable ( request , course_id , commentable_id ) : user = cc . User . from_django_user ( request . user ) commentable = cc . Commentable . find ( commentable_id ) user . unfollow ( commentable ) return JsonResponse ( { } )
given a course id and commentable id stop following commentable ajax only .