We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 481bbff commit fc6b79cCopy full SHA for fc6b79c
beaker/util.py
@@ -315,8 +315,10 @@ def coerce_session_params(params):
315
if cookie_expires and isinstance(cookie_expires, int) and \
316
not isinstance(cookie_expires, bool):
317
opts['cookie_expires'] = timedelta(seconds=cookie_expires)
318
- if opts['timeout'] is not None and not opts['save_accessed_time']:
+
319
+ if opts.get('timeout') is not None and not opts.get('save_accessed_time', True):
320
raise Exception("save_accessed_time must be true to use timeout")
321
322
return opts
323
324
@@ -462,7 +464,7 @@ def dumps(self, data):
462
464
return zlib.compress(json.dumps(data).encode('utf-8'))
463
465
466
-def serialize(data, serializer):
467
+def serialize(data, method):
468
if method == 'json':
469
serializer = JsonSerializer()
470
else:
0 commit comments