]> git.lizzy.rs Git - cheatdb.git/blob - app/blueprints/__init__.py
Add ability to edit comments
[cheatdb.git] / app / blueprints / __init__.py
1 import os, importlib
2
3 def create_blueprints(app):
4         dir = os.path.dirname(os.path.realpath(__file__))
5         modules = next(os.walk(dir))[1] 
6         
7         for modname in modules:         
8                 if all(c.islower() for c in modname):
9                         module = importlib.import_module("." + modname, __name__)               
10                         app.register_blueprint(module.bp)