bornhack-website/src/bornhack/routing.py

14 lines
349 B
Python

from channels.auth import AuthMiddlewareStack
from channels.routing import ProtocolTypeRouter, URLRouter
from django.conf.urls import url
from program.consumers import ScheduleConsumer
application = ProtocolTypeRouter(
{
"websocket": AuthMiddlewareStack(
URLRouter([url(r"^schedule/", ScheduleConsumer)])
)
}
)