Update to latest version from https://github.com/altran/Whydah-TestWebApp/blob/master/ImplementationExamples/Django/middleware.py