django_dynamic_theme.middleware

Middlewares for the dynamic theme app.

Classes

MissingThemeHandleMiddleware

Detects if the theme file is missing.

Module Contents

class django_dynamic_theme.middleware.MissingThemeHandleMiddleware(get_response)

Detects if the theme file is missing.

__call__(request)
process_exception(request, exception)

If a default theme is set it will export this one. If there is not default theme it will export the first one. If no theme exists it will raise an error.