diff --git a/CTFd/utils/decorators/__init__.py b/CTFd/utils/decorators/__init__.py index e262b3b2..c30cf2bc 100644 --- a/CTFd/utils/decorators/__init__.py +++ b/CTFd/utils/decorators/__init__.py @@ -84,7 +84,7 @@ def authed_only(f): if authed(): return f(*args, **kwargs) else: - if request.content_type == "application/json": + if request.content_type == "application/json" or request.accept_mimetypes.best == "text/event-stream": abort(403) else: return redirect(url_for("auth.login", next=request.full_path))