'Utility function to get a submenu of the current menu'

def _get_sub_menu(self, current_menu, key, label, position=None):

    extension_menu = current_menu.get_or_create_menu(key, label, position=position)
    return extension_menu
