Skip to content

Commit

Permalink
if user defaults to None as explicit param, set to empty dict
Browse files Browse the repository at this point in the history
  • Loading branch information
maxxiefjv authored and c00kiemon5ter committed Sep 3, 2021
1 parent 7408566 commit 0fbb18c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/pyop/storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,9 @@ class RedisWrapper(StorageBase):
"""

def __init__(self, db_uri, collection, ttl=None, options={}):
if options is None:
options = {}

if not _has_redis:
raise ImportError("redis module is required but it is not available")
self._db = Redis.from_url(db_uri, decode_responses=True, **options.get('redis_kwargs', {}))
Expand Down

0 comments on commit 0fbb18c

Please sign in to comment.