From 88334f67bea5b66237de8868822e691621a973c8 Mon Sep 17 00:00:00 2001 From: Ben Wiederhake Date: Sat, 13 May 2023 13:08:04 +0200 Subject: [PATCH] HackStudio: Prefer FileSystem over DeprecatedFile --- Userland/DevTools/HackStudio/HackStudioWidget.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Userland/DevTools/HackStudio/HackStudioWidget.cpp b/Userland/DevTools/HackStudio/HackStudioWidget.cpp index 97b45ccc25..9a970632a6 100644 --- a/Userland/DevTools/HackStudio/HackStudioWidget.cpp +++ b/Userland/DevTools/HackStudio/HackStudioWidget.cpp @@ -27,7 +27,6 @@ #include #include #include -#include #include #include #include @@ -903,10 +902,11 @@ NonnullRefPtr HackStudioWidget::create_save_as_action() auto const old_filename = current_editor_wrapper().filename(); LexicalPath const old_path(old_filename); + auto suggested_path = FileSystem::absolute_path(old_path.string()).release_value_but_fixme_should_propagate_errors(); Optional save_path = GUI::FilePicker::get_save_filepath(window(), old_filename.is_null() ? "Untitled"sv : old_path.title(), old_filename.is_null() ? "txt"sv : old_path.extension(), - Core::DeprecatedFile::absolute_path(old_path.dirname())); + suggested_path); if (!save_path.has_value()) { return; }