import os
from django.core.asgi import get_asgi_application
from channels.routing import ProtocolTypeRouter, URLRouter

os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'config.settings')
django_asgi_app = get_asgi_application()

from focara.routing import websocket_urlpatterns as focara_ws
from nomazra.routing import websocket_urlpatterns as nomazra_ws

application = ProtocolTypeRouter({
    'http': django_asgi_app,
    'websocket': URLRouter(focara_ws + nomazra_ws),
})
