def process_response(self, request, response):
        """
        Update the storage backend (i.e., save the resume points).

        Raise ValueError if not all resume points could be stored and DEBUG is True.
        """
        # A higher middleware layer may return a request which does not contain
        # resume storage, so make no assumption that it will be there.
        if hasattr(request, "_ga_events"):
            request._ga_events.store()
        return response

        Update the storage backend (i.e., save the resume points).

        Raise ValueError if not all resume points could be stored and DEBUG is True.
        
simple_ga/middleware.py