Skip to content

Commit 2146c88

Browse files
committed
src: fix NewContext for --without-intl
PR-URL: #16251 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: James M Snell <[email protected]>
1 parent 7a71cd7 commit 2146c88

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/node.cc

+2-2
Original file line numberDiff line numberDiff line change
@@ -4787,9 +4787,9 @@ Local<Context> NewContext(Isolate* isolate,
47874787
auto intl_key = FIXED_ONE_BYTE_STRING(isolate, "Intl");
47884788
auto break_iter_key = FIXED_ONE_BYTE_STRING(isolate, "v8BreakIterator");
47894789
Local<Value> intl_v;
4790-
Local<Object> intl;
47914790
if (context->Global()->Get(context, intl_key).ToLocal(&intl_v) &&
4792-
intl_v->ToObject(context).ToLocal(&intl)) {
4791+
intl_v->IsObject()) {
4792+
Local<Object> intl = intl_v.As<Object>();
47934793
intl->Delete(context, break_iter_key).FromJust();
47944794
}
47954795
return context;

0 commit comments

Comments
 (0)