Browse Source

Merge pull request #417 from tarruda/master

Fixed assumption made on session implementations
pull/451/merge
Ron DuPlain 13 years ago
parent
commit
71a9766266
  1. 4
      flask/helpers.py

4
flask/helpers.py

@ -283,7 +283,9 @@ def flash(message, category='message'):
messages and ``'warning'`` for warnings. However any
kind of string can be used as category.
"""
session.setdefault('_flashes', []).append((category, message))
flashes = session.get('_flashes', [])
flashes.append((category, message))
session['_flashes'] = flashes
def get_flashed_messages(with_categories=False, category_filter=[]):

Loading…
Cancel
Save