diff --git a/emergent/views.py b/emergent/views.py index 8af3b4f..b638c25 100644 --- a/emergent/views.py +++ b/emergent/views.py @@ -84,7 +84,7 @@ def get_context_data(self, **kwargs): context['users'] = get_user_model().objects.all() return context -class ChatView(TemplateView): +class ChatView(LoginRequiredMixin, TemplateView): template_name = 'emergent/chat.html' def get_context_data(self, **kwargs): @@ -92,7 +92,7 @@ def get_context_data(self, **kwargs): return context -class ChatSendView(JSONResponseMixin, AjaxResponseMixin, View): +class ChatSendView(LoginRequiredMixin, JSONResponseMixin, AjaxResponseMixin, View): def post_ajax(self, request, *args, **kwargs): import pusher