Skip to content

Commit

Permalink
fix: avoid Identifier 'global' has already been declared (#30)
Browse files Browse the repository at this point in the history
  • Loading branch information
bluelovers authored Apr 6, 2020
1 parent 21c2f1e commit f468065
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
3 changes: 1 addition & 2 deletions src/http.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@
const fetch = require('node-fetch')
const merge = require('merge-options')
const { URL, URLSearchParams } = require('iso-url')
const global = require('./globalthis')
const TextDecoder = require('./text-encoder')
const Request = global.Request
const Request = require('./globalthis').Request
const AbortController = require('abort-controller')

class TimeoutError extends Error {
Expand Down
4 changes: 1 addition & 3 deletions src/text-encoder.browser.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
'use strict'

const global = require('./globalthis')

module.exports = global.TextDecoder
module.exports = require('./globalthis').TextDecoder

0 comments on commit f468065

Please sign in to comment.