import re from flask_login import current_user from framework import F def get_menu(full_query): match = re.compile(r'\/(?P