Starting a large refactor and adding confirmation abilities

This commit is contained in:
Matt Wright
2012-05-11 13:23:42 -04:00
parent 1ae711279e
commit 2b587f7047
17 changed files with 633 additions and 528 deletions
+7
View File
@@ -9,11 +9,18 @@
:license: MIT, see LICENSE for more details.
"""
import base64
import os
from importlib import import_module
from flask import url_for, flash, current_app, request, session
def generate_token():
return base64.urlsafe_b64encode(os.urandom(30))
def do_flash(message, category):
if config_value(current_app, 'FLASH_MESSAGES'):
flash(message, category)