Bug 1068589 - Remove forced extensible check before calling JSObject::preventExtensions. r=jwalden
This commit is contained in:
@@ -1267,10 +1267,7 @@ JSObject::sealOrFreeze(JSContext *cx, HandleObject obj, ImmutabilityType it)
|
||||
assertSameCompartment(cx, obj);
|
||||
JS_ASSERT(it == SEAL || it == FREEZE);
|
||||
|
||||
bool extensible;
|
||||
if (!JSObject::isExtensible(cx, obj, &extensible))
|
||||
return false;
|
||||
if (extensible && !JSObject::preventExtensions(cx, obj))
|
||||
if (!JSObject::preventExtensions(cx, obj))
|
||||
return false;
|
||||
|
||||
AutoIdVector props(cx);
|
||||
|
||||
Reference in New Issue
Block a user