Exemple #1
0
    def process_response(self, request, response):
        """This method is called by the Django framework when a *response* is
        sent back to the user.
        """
        flash = _get_flash_from_request(request)
        if flash:
            storage.set(flash, request, response)
        else:
            _get_flash_from_storage(request)

        return response
Exemple #2
0
    def process_response(self, request, response):
        """This method is called by the Django framework when a *response* is
        sent back to the user.
        """
        flash = _get_flash_from_request(request)
        if flash:
            storage.set(flash, request, response)
        else:
            _get_flash_from_storage(request)

        return response
 def process_response(self, request, response):
     """This method is called by the Django framework when a *response* is
     sent back to the user.
     """
     storage.set(self._get_flash_from_request(request), request, response)
     return response