why is session.forget not callable in tests?

This commit is contained in:
mdipierro
2016-06-12 21:08:33 -05:00
parent dfb0129f09
commit a18e0e489f
+2 -1
View File
@@ -6234,7 +6234,8 @@ class Expose(object):
and file creation under `base`.
"""
current.session and current.session.forget()
# why would this not be callable? but otherwise tests do not pass
if current.session and callable(current.session.forget): current.session.forget()
self.follow_symlink_out = follow_symlink_out
self.base = self.normalize_path(
base or os.path.join(current.request.folder, 'static'))