diff --git a/Libraries/LibJS/Runtime/Shape.cpp b/Libraries/LibJS/Runtime/Shape.cpp index d30c701c60..741e00e322 100644 --- a/Libraries/LibJS/Runtime/Shape.cpp +++ b/Libraries/LibJS/Runtime/Shape.cpp @@ -114,6 +114,8 @@ void Shape::visit_children(Cell::Visitor& visitor) Optional Shape::lookup(const StringOrSymbol& property_name) const { + if (m_property_count == 0) + return {}; auto property = property_table().get(property_name); if (!property.has_value()) return {};