1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 21:37:35 +00:00

Spreadsheet: Make file export functions return ErrorOr<>

This commit is contained in:
Karol Kosek 2022-12-31 15:38:12 +01:00 committed by Ali Mohammad Pur
parent 29a3cdcfb7
commit 5793f7749c
5 changed files with 59 additions and 68 deletions

View file

@ -497,7 +497,7 @@ void SpreadsheetWidget::save(Core::File& file)
{
auto result = m_workbook->write_to_file(file);
if (result.is_error()) {
GUI::MessageBox::show_error(window(), result.error());
GUI::MessageBox::show_error(window(), DeprecatedString::formatted("Cannot save file: {}", result.error()));
return;
}
undo_stack().set_current_unmodified();