Mercurial > kallithea
changeset 1930:a69573cfcb00 beta
cleanup task session only if celery is on
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Fri, 20 Jan 2012 08:14:32 +0200 |
parents | cd8a7e3698bc |
children | b6c849e64b37 |
files | rhodecode/lib/celerylib/__init__.py |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/rhodecode/lib/celerylib/__init__.py Fri Jan 20 08:11:00 2012 +0200 +++ b/rhodecode/lib/celerylib/__init__.py Fri Jan 20 08:14:32 2012 +0200 @@ -122,6 +122,7 @@ ret = func(*fargs, **fkwargs) return ret finally: - meta.Session.remove() + if CELERY_ON: + meta.Session.remove() return decorator(__wrapper, func)