mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 06:07:34 +00:00
Spreadsheet: Port from Result
to ErrorOr
This commit is contained in:
parent
4952cdfe2b
commit
81008062a7
4 changed files with 15 additions and 27 deletions
|
@ -52,7 +52,7 @@ bool Workbook::set_filename(DeprecatedString const& filename)
|
|||
return true;
|
||||
}
|
||||
|
||||
Result<bool, DeprecatedString> Workbook::open_file(Core::File& file)
|
||||
ErrorOr<void, DeprecatedString> Workbook::open_file(Core::File& file)
|
||||
{
|
||||
auto mime = Core::guess_mime_type_based_on_filename(file.filename());
|
||||
|
||||
|
@ -61,7 +61,7 @@ Result<bool, DeprecatedString> Workbook::open_file(Core::File& file)
|
|||
|
||||
set_filename(file.filename());
|
||||
|
||||
return true;
|
||||
return {};
|
||||
}
|
||||
|
||||
ErrorOr<void> Workbook::write_to_file(Core::File& file)
|
||||
|
@ -78,7 +78,7 @@ ErrorOr<void> Workbook::write_to_file(Core::File& file)
|
|||
return {};
|
||||
}
|
||||
|
||||
Result<bool, DeprecatedString> Workbook::import_file(Core::File& file)
|
||||
ErrorOr<bool, DeprecatedString> Workbook::import_file(Core::File& file)
|
||||
{
|
||||
auto mime = Core::guess_mime_type_based_on_filename(file.filename());
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue