From 6e3392926264f9d7ff8dc9b44303f8635361d3ca Mon Sep 17 00:00:00 2001 From: Daniel Bevenius Date: Wed, 3 Jun 2020 05:54:14 +0200 Subject: [PATCH] src: use Check() instead of FromJust in environment This commit replaces FromJust() calls with Check() in places where the value that FromJust() returns is not used. PR-URL: https://github.com/nodejs/node/pull/33706 Reviewed-By: Colin Ihrig Reviewed-By: James M Snell Reviewed-By: David Carlier --- src/api/environment.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/api/environment.cc b/src/api/environment.cc index 5349657d4c5a8d..20408c79f858be 100644 --- a/src/api/environment.cc +++ b/src/api/environment.cc @@ -553,7 +553,7 @@ void InitializeContextRuntime(Local context) { if (context->Global()->Get(context, intl_string).ToLocal(&intl_v) && intl_v->IsObject()) { Local intl = intl_v.As(); - intl->Delete(context, break_iter_string).FromJust(); + intl->Delete(context, break_iter_string).Check(); } // Delete `Atomics.wake` @@ -564,7 +564,7 @@ void InitializeContextRuntime(Local context) { if (context->Global()->Get(context, atomics_string).ToLocal(&atomics_v) && atomics_v->IsObject()) { Local atomics = atomics_v.As(); - atomics->Delete(context, wake_string).FromJust(); + atomics->Delete(context, wake_string).Check(); } // Remove __proto__