msw 2.4.8 → 2.4.10

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.
@@ -174,16 +174,15 @@ var getWorkerInstance = async (url, options = {}, findWorker) => {
174
174
  }
175
175
  const [existingRegistration] = mockRegistrations;
176
176
  if (existingRegistration) {
177
- return existingRegistration.update().then(() => {
178
- return [
179
- getWorkerByRegistration(
180
- existingRegistration,
181
- absoluteWorkerUrl,
182
- findWorker
183
- ),
184
- existingRegistration
185
- ];
186
- });
177
+ existingRegistration.update();
178
+ return [
179
+ getWorkerByRegistration(
180
+ existingRegistration,
181
+ absoluteWorkerUrl,
182
+ findWorker
183
+ ),
184
+ existingRegistration
185
+ ];
187
186
  }
188
187
  const registrationResult = await until(
189
188
  async () => {
@@ -397,7 +396,7 @@ You can also automate this process and make the worker script update automatical
397
396
  }
398
397
  }
399
398
 
400
- // node_modules/.pnpm/@mswjs+interceptors@0.35.6/node_modules/@mswjs/interceptors/lib/browser/chunk-6HYIRFX2.mjs
399
+ // node_modules/.pnpm/@mswjs+interceptors@0.35.8/node_modules/@mswjs/interceptors/lib/browser/chunk-6HYIRFX2.mjs
401
400
  var encoder = new TextEncoder();
402
401
  function encodeBuffer(text) {
403
402
  return encoder.encode(text);
@@ -413,7 +412,7 @@ function toArrayBuffer(array) {
413
412
  );
414
413
  }
415
414
 
416
- // node_modules/.pnpm/@mswjs+interceptors@0.35.6/node_modules/@mswjs/interceptors/lib/browser/chunk-XVPRNJO7.mjs
415
+ // node_modules/.pnpm/@mswjs+interceptors@0.35.8/node_modules/@mswjs/interceptors/lib/browser/chunk-XVPRNJO7.mjs
417
416
  var IS_PATCHED_MODULE = Symbol("isPatchedModule");
418
417
  function isPropertyAccessible(obj, key) {
419
418
  try {
@@ -983,7 +982,7 @@ var _Emitter = class {
983
982
  var Emitter = _Emitter;
984
983
  Emitter.defaultMaxListeners = 10;
985
984
 
986
- // node_modules/.pnpm/@mswjs+interceptors@0.35.6/node_modules/@mswjs/interceptors/lib/browser/chunk-QED3Q6Z2.mjs
985
+ // node_modules/.pnpm/@mswjs+interceptors@0.35.8/node_modules/@mswjs/interceptors/lib/browser/chunk-QED3Q6Z2.mjs
987
986
  var INTERNAL_REQUEST_ID_HEADER_NAME = "x-interceptors-internal-request-id";
988
987
  function getGlobalSymbol(symbol) {
989
988
  return (
@@ -1131,7 +1130,7 @@ function createRequestId() {
1131
1130
  return Math.random().toString(16).slice(2);
1132
1131
  }
1133
1132
 
1134
- // node_modules/.pnpm/@mswjs+interceptors@0.35.6/node_modules/@mswjs/interceptors/lib/browser/index.mjs
1133
+ // node_modules/.pnpm/@mswjs+interceptors@0.35.8/node_modules/@mswjs/interceptors/lib/browser/index.mjs
1135
1134
  var BatchInterceptor = class extends Interceptor {
1136
1135
  constructor(options) {
1137
1136
  BatchInterceptor.symbol = Symbol(options.name);
@@ -1415,7 +1414,7 @@ var DeferredPromise = class extends Promise {
1415
1414
  }
1416
1415
  };
1417
1416
 
1418
- // node_modules/.pnpm/@mswjs+interceptors@0.35.6/node_modules/@mswjs/interceptors/lib/browser/chunk-THPGBWJQ.mjs
1417
+ // node_modules/.pnpm/@mswjs+interceptors@0.35.8/node_modules/@mswjs/interceptors/lib/browser/chunk-THPGBWJQ.mjs
1419
1418
  var InterceptorError = class extends Error {
1420
1419
  constructor(message) {
1421
1420
  super(message);
@@ -1583,7 +1582,7 @@ async function handleRequest2(options) {
1583
1582
  return false;
1584
1583
  }
1585
1584
 
1586
- // node_modules/.pnpm/@mswjs+interceptors@0.35.6/node_modules/@mswjs/interceptors/lib/browser/chunk-G5SOR3ND.mjs
1585
+ // node_modules/.pnpm/@mswjs+interceptors@0.35.8/node_modules/@mswjs/interceptors/lib/browser/chunk-G5SOR3ND.mjs
1587
1586
  function canParseUrl(url) {
1588
1587
  try {
1589
1588
  new URL(url);
@@ -1780,7 +1779,7 @@ var _FetchInterceptor = class extends Interceptor {
1780
1779
  var FetchInterceptor = _FetchInterceptor;
1781
1780
  FetchInterceptor.symbol = Symbol("fetch");
1782
1781
 
1783
- // node_modules/.pnpm/@mswjs+interceptors@0.35.6/node_modules/@mswjs/interceptors/lib/browser/chunk-SUQ32ZQK.mjs
1782
+ // node_modules/.pnpm/@mswjs+interceptors@0.35.8/node_modules/@mswjs/interceptors/lib/browser/chunk-SUQ32ZQK.mjs
1784
1783
  function concatArrayBuffer(left, right) {
1785
1784
  const result = new Uint8Array(left.byteLength + right.byteLength);
1786
1785
  result.set(left, 0);