+Board*
+boardmenu_to_board(BoardMenu* boardmenu)
+{ // STRINGS are sharing the same address as the one in MENU
+ // and MENUITEM, this may break something if u free this board
+ // consider copying the string
+
+ Board* newboard = malloc(sizeof(Board));
+ TodoList** new_todolist_list = malloc(sizeof(TodoList*));
+
+ for (int i = 0; i < boardmenu->menu_count; i++) {
+ Menu* curmenu = boardmenu->menu_list[i];
+
+ TodoList* new_todolist = malloc(sizeof(TodoList));
+ TodoItem** item_list = malloc(sizeof(TodoItem*));
+ new_todolist->list_name = get_menu_name(curmenu);
+ new_todolist->item_count = get_menu_length(curmenu);
+
+ for (int j = 0; j < get_menu_length(curmenu); j++) {
+ MenuItem* curmenuitem = get_menu_item(curmenu, j);
+
+ TodoItem* new_todoitem = malloc(sizeof(TodoItem));
+
+ new_todoitem->item_name = get_menuitem_title(curmenuitem);
+ new_todoitem->description = get_menuitem_descrip(curmenuitem);
+ new_todoitem->due = 0; //TEMP!
+ new_todoitem->subtask_list = 0; //TEMP!
+ new_todoitem->subtask_count = 0; //TEMP!
+
+ item_list[j] = new_todoitem;
+
+ }
+
+ new_todolist->item_list = item_list;
+
+ new_todolist_list[i] = new_todolist;
+
+ }
+
+ newboard->todolist_list = new_todolist_list;
+ newboard->todolist_count = boardmenu->menu_count;
+
+ return newboard;
+
+}
+