

def find(self, name, menu=None):
    '\n            Finds a menu item by name and returns it.\n\n            :param name:\n                The menu item name.\n        '
    menu = (menu or self.menu)
    for i in menu:
        if (i.name == name):
            return i
        elif i.childs:
            ret_item = self.find(name, menu=self.childs)
            if ret_item:
                return ret_item

dataset/ETHPy150Open dpgaspar/Flask-AppBuilder/flask_appbuilder/menu.py Menu.find/VarMisuse@67/117 `i`->`self`