@whatwg-node/fetch
Advanced tools
Comparing version 0.6.3 to 0.6.4
# @whatwg-node/fetch | ||
## 0.6.4 | ||
### Patch Changes | ||
- [`2ce7122`](https://github.com/ardatan/whatwg-node/commit/2ce71227f0cc86644998cad70405048d79c1b104) | ||
Thanks [@ardatan](https://github.com/ardatan)! - Bun doesn't have URLPattern | ||
## 0.6.3 | ||
@@ -4,0 +11,0 @@ |
module.exports = function createNodePonyfill(opts = {}) { | ||
// Bun already has a Fetch API | ||
if (process.versions.bun) { | ||
return globalThis; | ||
const ponyfills = {}; | ||
// We call this previously to patch `Bun` | ||
if (!ponyfills.URLPattern) { | ||
const urlPatternModule = require('urlpattern-polyfill'); | ||
ponyfills.URLPattern = urlPatternModule.URLPattern; | ||
} | ||
@@ -10,4 +12,2 @@ | ||
const ponyfills = {}; | ||
ponyfills.fetch = newNodeFetch.fetch; | ||
@@ -79,9 +79,4 @@ ponyfills.Request = newNodeFetch.Request; | ||
} | ||
if (!ponyfills.URLPattern) { | ||
const urlPatternModule = require('urlpattern-polyfill'); | ||
ponyfills.URLPattern = urlPatternModule.URLPattern; | ||
} | ||
return ponyfills; | ||
} |
{ | ||
"name": "@whatwg-node/fetch", | ||
"version": "0.6.3", | ||
"version": "0.6.4", | ||
"description": "Cross Platform Smart Fetch Ponyfill", | ||
@@ -5,0 +5,0 @@ "repository": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
22921
219