diff options
author | Shelley Vohr <shelley.vohr@gmail.com> | 2020-06-25 18:07:37 -0700 |
---|---|---|
committer | Shelley Vohr <shelley.vohr@gmail.com> | 2020-06-29 09:12:11 -0700 |
commit | c23d2fd3f8a018bcc624f1468a9ce176f6ce93f2 (patch) | |
tree | 4f868038dc77b7eb64d091ee55ae59729293a0b8 /src/env-inl.h | |
parent | 9e135accbb045d52eb65de602c81b5090daae1c4 (diff) | |
download | node-new-c23d2fd3f8a018bcc624f1468a9ce176f6ce93f2.tar.gz |
src: allow embedders to disable esm loader
PR-URL: https://github.com/nodejs/node/pull/34060
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: David Carlier <devnexen@gmail.com>
Reviewed-By: Gus Caplan <me@gus.host>
Diffstat (limited to 'src/env-inl.h')
-rw-r--r-- | src/env-inl.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/env-inl.h b/src/env-inl.h index 5cbb2cd60b..690e797043 100644 --- a/src/env-inl.h +++ b/src/env-inl.h @@ -767,6 +767,10 @@ inline bool Environment::is_main_thread() const { return worker_context() == nullptr; } +inline bool Environment::should_not_register_esm_loader() const { + return flags_ & EnvironmentFlags::kNoRegisterESMLoader; +} + inline bool Environment::owns_process_state() const { return flags_ & EnvironmentFlags::kOwnsProcessState; } |