def flash(message, category='message'):
 flashes = session.get('_flashes', [])
 flashes.append((category, message))
 session['_flashes'] = flashes
 message_flashed.send(current_app._get_current_object(), message=message, category=category)

def flash ( message , category = 'message' ) : flashes = session . get ( '_flashes' , [ ] ) flashes . append ( ( category , message ) ) session [ '_flashes' ] = flashes message_flashed . send ( current_app . _get_current_object ( ) , message = message , category = category )
flashes a message to the next request .