Socket
Socket
Sign inDemoInstall

webtorrent

Package Overview
Dependencies
Maintainers
0
Versions
529
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

webtorrent - npm Package Compare versions

Comparing version 2.4.10 to 2.4.11

13

lib/torrent.js

@@ -1,2 +0,1 @@

/* global FileSystemFileHandle */
import EventEmitter from 'events'

@@ -14,3 +13,3 @@ import fs from 'fs'

import Discovery from 'torrent-discovery'
import FSChunkStore from 'fs-chunk-store' // browser: `fsa-chunk-store`
import FSChunkStore from 'fs-chunk-store' // browser: `hybrid-chunk-store`
import fetch from 'cross-fetch-ponyfill'

@@ -20,2 +19,3 @@ import ImmediateChunkStore from 'immediate-chunk-store'

import MemoryChunkStore from 'memory-chunk-store'
import HybridChunkStore from 'hybrid-chunk-store'
import joinIterator from 'join-async-iterator'

@@ -63,7 +63,2 @@ import parallel from 'run-parallel'

const SUPPORTS_FSA = (typeof navigator !== 'undefined' && navigator.storage?.getDirectory && typeof FileSystemFileHandle !== 'undefined' && FileSystemFileHandle?.prototype?.createWritable)
const FALLBACK_STORE = !process.browser || SUPPORTS_FSA
? FSChunkStore // Node or browser with FSA
: MemoryChunkStore
let TMP

@@ -92,3 +87,3 @@ try {

this.skipVerify = !!opts.skipVerify
this._store = opts.store || FALLBACK_STORE
this._store = opts.store || FSChunkStore
this._preloadedStore = opts.preloadedStore || null

@@ -550,3 +545,3 @@ this._storeCacheSlots = opts.storeCacheSlots !== undefined ? opts.storeCacheSlots : 20

// don't use the cache if the store is already in memory
if (this._storeCacheSlots > 0 && !(rawStore instanceof MemoryChunkStore)) {
if (this._storeCacheSlots > 0 && !(rawStore instanceof MemoryChunkStore || rawStore instanceof HybridChunkStore)) {
rawStore = new CacheChunkStore(rawStore, {

@@ -553,0 +548,0 @@ max: this._storeCacheSlots

{
"name": "webtorrent",
"description": "Streaming torrent client",
"version": "2.4.10",
"version": "2.4.11",
"author": {

@@ -18,3 +18,3 @@ "name": "WebTorrent LLC",

"fs": false,
"fs-chunk-store": "fsa-chunk-store",
"fs-chunk-store": "hybrid-chunk-store",
"http": false,

@@ -56,3 +56,3 @@ "load-ip-set": false,

"fs-chunk-store": "^4.1.0",
"fsa-chunk-store": "^1.1.5",
"hybrid-chunk-store": "^1.2.6",
"immediate-chunk-store": "^2.2.0",

@@ -104,3 +104,2 @@ "join-async-iterator": "^1.1.1",

"finalhandler": "1.2.0",
"native-file-system-adapter": "^3.0.1",
"network-address": "1.1.2",

@@ -107,0 +106,0 @@ "pako": "^2.1.0",

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc