diff --git a/client/src/tui/functions/intro.rs b/client/src/tui/functions/intro.rs index de92f12..ca0d055 100644 --- a/client/src/tui/functions/intro.rs +++ b/client/src/tui/functions/intro.rs @@ -13,10 +13,10 @@ pub fn handle_intro_selection( index: usize, ) { let target_view = match index { - 0 => buffer_state.history.iter().rev() - .find(|v| matches!(v, AppView::Form(_))) - .cloned() - .unwrap_or_else(|| AppView::Form("Default".to_string())), + 0 => { + let form_name = app_state.selected_profile.clone().unwrap_or_else(|| "Data Form".to_string()); + AppView::Form(form_name) + } 1 => AppView::Admin, 2 => AppView::Login, 3 => AppView::Register,