From 4788c94d344d32207e0bc13dae60fb2616aa25fa Mon Sep 17 00:00:00 2001 From: Linus Groh Date: Sat, 10 Apr 2021 17:39:32 +0200 Subject: [PATCH] LibJS: Remove superfluous exception check from get_own_property_descriptor() Accessing elements of the storage Vector can't throw. --- Userland/Libraries/LibJS/Runtime/Object.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/Userland/Libraries/LibJS/Runtime/Object.cpp b/Userland/Libraries/LibJS/Runtime/Object.cpp index 5c5d48a879..2a92344f46 100644 --- a/Userland/Libraries/LibJS/Runtime/Object.cpp +++ b/Userland/Libraries/LibJS/Runtime/Object.cpp @@ -372,8 +372,6 @@ Optional Object::get_own_property_descriptor(const PropertyN if (!metadata.has_value()) return {}; value = m_storage[metadata.value().offset]; - if (vm().exception()) - return {}; attributes = metadata.value().attributes; }