Skip to content

Commit

Permalink
Test for nodejs fixes johntron#21
Browse files Browse the repository at this point in the history
  • Loading branch information
piascikj committed May 8, 2017
1 parent 2f08e2a commit d002645
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
var ie = require('component-ie')
var isNode = Object.prototype.toString.call(typeof process !== 'undefined' ? process : 0) === '[object process]'

function with_query_strings (request) {
var timestamp = Date.now().toString()
Expand All @@ -16,7 +16,7 @@ module.exports = function _superagentNoCache (request, mockIE) {
request.set('Expires', '-1')
request.set('Cache-Control', 'no-cache,no-store,must-revalidate,max-age=-1,private')

if (ie || mockIE) {
if ((!isNode && require('component-ie')) || mockIE) {
with_query_strings(request)
}

Expand Down

0 comments on commit d002645

Please sign in to comment.