'Returns True if the headers indicate that we should return 304.
.. versionadded:: 3.1'

def should_return_304(self):

    if self.check_etag_header():
        return True
    ims_value = self.request.headers.get('If-Modified-Since')
    if (ims_value is not None):
        date_tuple = email.utils.parsedate(ims_value)
        if (date_tuple is not None):
            if_since = datetime.datetime(*date_tuple[:6])
            if (if_since >= self.modified):
                return True
    return False
