@rotorsoft/act 2.1.8 → 2.1.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -11,8 +11,10 @@ import {
11
11
  LruMap,
12
12
  MAX_SHUTDOWN_GRACE_MS,
13
13
  cache,
14
+ check_audit_options,
14
15
  check_scan_options,
15
16
  check_store,
17
+ check_target,
16
18
  config,
17
19
  current_autoclose_window,
18
20
  current_reacting,
@@ -35,12 +37,11 @@ import {
35
37
  resolveReactionConfig,
36
38
  resolveSettleConfig,
37
39
  resolveShutdownConfig,
38
- resolveTargetConfig,
39
40
  sleep,
40
41
  store,
41
42
  unscoped_ports,
42
43
  validate
43
- } from "./chunk-GUMG5AVZ.js";
44
+ } from "./chunk-NYDHZSYZ.js";
44
45
  import {
45
46
  checkAppends,
46
47
  checkVersion,
@@ -4314,6 +4315,7 @@ var Act = class {
4314
4315
  * ```
4315
4316
  */
4316
4317
  async *audit(categories, options) {
4318
+ check_audit_options(options);
4317
4319
  const it = audit(this._audit_deps, categories, options)[Symbol.asyncIterator]();
4318
4320
  while (true) {
4319
4321
  const { value, done } = await this._scoped(() => it.next());
@@ -4341,7 +4343,7 @@ var Act = class {
4341
4343
  * @see {@link Store.prioritize} for the underlying primitive
4342
4344
  */
4343
4345
  async prioritize(filter, priority) {
4344
- resolveTargetConfig({ priority });
4346
+ check_target({ priority });
4345
4347
  return this._scoped(() => store().prioritize(filter, priority));
4346
4348
  }
4347
4349
  // Shared by `close()` and reaction-requested closes.
@@ -4643,7 +4645,7 @@ function add_reaction(events, event, name, kind, make, builder) {
4643
4645
  events[event].reactions.set(name, reaction);
4644
4646
  return Object.assign(builder, {
4645
4647
  to(resolver) {
4646
- if (typeof resolver === "object") resolveTargetConfig(resolver);
4648
+ if (typeof resolver === "object") check_target(resolver);
4647
4649
  reaction.resolver = typeof resolver === "string" ? { target: resolver } : resolver;
4648
4650
  return builder;
4649
4651
  }