

def __init__(self, cache_timeout=None, **kwargs):
    try:
        key_prefix = kwargs['key_prefix']
        if (key_prefix is None):
            key_prefix = ''
    except KeyError:
        key_prefix = settings.CACHE_MIDDLEWARE_KEY_PREFIX
    self.key_prefix = key_prefix
    try:
        cache_alias = kwargs['cache_alias']
        if (cache_alias is None):
            cache_alias = DEFAULT_CACHE_ALIAS
    except KeyError:
        cache_alias = settings.CACHE_MIDDLEWARE_ALIAS
    self.cache_alias = cache_alias
    if (cache_timeout is None):
        cache_timeout = settings.CACHE_MIDDLEWARE_SECONDS
    self.cache_timeout = cache_timeout
    self.cache = caches[self.cache_alias]

dataset/ETHPy150Open django/django/django/middleware/cache.py CacheMiddleware.__init__/original