mirror of
https://github.com/RGBCube/serenity
synced 2025-06-01 02:28:12 +00:00
Spreadsheet: Avoid using Value.to_string_without_side_effects()
We should use .to_string() and handle the possible exceptions. This makes the displayed cell contents so much more informative than '[object Object]' :^)
This commit is contained in:
parent
235eb0b1ad
commit
5f1a34bba3
13 changed files with 72 additions and 53 deletions
|
@ -74,12 +74,12 @@ const CellType& Cell::type() const
|
|||
return *CellType::get_by_name("Identity");
|
||||
}
|
||||
|
||||
String Cell::typed_display() const
|
||||
JS::ThrowCompletionOr<String> Cell::typed_display() const
|
||||
{
|
||||
return type().display(const_cast<Cell&>(*this), m_type_metadata);
|
||||
}
|
||||
|
||||
JS::Value Cell::typed_js_data() const
|
||||
JS::ThrowCompletionOr<JS::Value> Cell::typed_js_data() const
|
||||
{
|
||||
return type().js_value(const_cast<Cell&>(*this), m_type_metadata);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue