mirror of
https://github.com/django/daphne.git
synced 2025-06-27 16:33:04 +03:00
Fixed #477: Only re-save session if it's not empty
This commit is contained in:
parent
5c74ee587e
commit
db8a4570c3
|
@ -70,7 +70,7 @@ def channel_session(func):
|
||||||
return func(message, *args, **kwargs)
|
return func(message, *args, **kwargs)
|
||||||
finally:
|
finally:
|
||||||
# Persist session if needed
|
# Persist session if needed
|
||||||
if session.modified:
|
if session.modified and not session.is_empty():
|
||||||
session.save()
|
session.save()
|
||||||
return inner
|
return inner
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user