@zip.js/zip.js 2.8.14 → 2.8.16

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/index.cjs CHANGED
@@ -1958,8 +1958,7 @@ class ChunkStream extends TransformStream {
1958
1958
  */
1959
1959
 
1960
1960
 
1961
- // deno-lint-ignore valid-typeof
1962
- let WEB_WORKERS_SUPPORTED = typeof Worker != UNDEFINED_TYPE;
1961
+ let WEB_WORKERS_SUPPORTED;
1963
1962
  let initModule$1 = () => { };
1964
1963
 
1965
1964
  function configureWorker({ initModule: initModuleFunction }) {
@@ -2007,6 +2006,10 @@ class CodecWorker {
2007
2006
  onTaskFinished(workerData);
2008
2007
  }
2009
2008
  });
2009
+ if (WEB_WORKERS_SUPPORTED === UNDEFINED_VALUE) {
2010
+ // deno-lint-ignore valid-typeof
2011
+ WEB_WORKERS_SUPPORTED = typeof Worker != UNDEFINED_TYPE;
2012
+ }
2010
2013
  return (useWebWorkers && WEB_WORKERS_SUPPORTED ? createWebWorkerInterface : createWorkerInterface)(workerData, config);
2011
2014
  }
2012
2015
  }
package/index.d.ts CHANGED
@@ -1331,8 +1331,8 @@ export class ZipWriter<Type> {
1331
1331
  ): Promise<EntryMetaData>;
1332
1332
 
1333
1333
  /**
1334
- * Removes an entry from the zip file. Note that the entry is not removed from the zip file, but it
1335
- * is not written to the entries directory.
1334
+ * Removes an entry from the central directory that will be written for the zip file. The entry
1335
+ * data itself cannot be removed because it has already been streamed to the output.
1336
1336
  *
1337
1337
  * @param entry The entry to remove. This can be an {@link Entry} instance or the filename of the entry.
1338
1338
  * @returns `true` if the entry has been removed, `false` otherwise.
@@ -1529,9 +1529,9 @@ export interface ZipWriterConstructorOptions extends WorkerConfiguration {
1529
1529
  /**
1530
1530
  * `true` to add a data descriptor.
1531
1531
  *
1532
- * When set to `false`, the {@link ZipWriterConstructorOptions#bufferedWrite} option will automatically be
1532
+ * When set to `false`, the {@link ZipWriterConstructorOptions#bufferedWrite} option will automatically be
1533
1533
  * set to `true`. It will be automatically set to `false` when it is `undefined` and the
1534
- * {@link ZipWriterConstructorOptions#bufferedWrite} option is set to `true`, or ` when the
1534
+ * {@link ZipWriterConstructorOptions#bufferedWrite} option is set to `true`, or when the
1535
1535
  * {@link ZipWriterConstructorOptions#zipCrypto} option is set to `true`. Otherwise, the default value is `true`.
1536
1536
  */
1537
1537
  dataDescriptor?: boolean;