mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 04:57:45 +00:00
HexEditor: Propagate HexDocumentFile creation errors in save_as()
This commit is contained in:
parent
034ec62cee
commit
8ae4464fa5
1 changed files with 1 additions and 1 deletions
|
@ -139,7 +139,7 @@ ErrorOr<void> HexEditor::save_as(NonnullOwnPtr<Core::File> new_file)
|
||||||
} else {
|
} else {
|
||||||
auto& memory_document = static_cast<HexDocumentMemory&>(*m_document);
|
auto& memory_document = static_cast<HexDocumentMemory&>(*m_document);
|
||||||
TRY(memory_document.write_to_file(*new_file));
|
TRY(memory_document.write_to_file(*new_file));
|
||||||
m_document = HexDocumentFile::create(move(new_file)).release_value_but_fixme_should_propagate_errors();
|
m_document = TRY(HexDocumentFile::create(move(new_file)));
|
||||||
}
|
}
|
||||||
|
|
||||||
update();
|
update();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue