浏览代码

删除无用包6

wangsy 11 月之前
父节点
当前提交
820d6d5a31
共有 100 个文件被更改,包括 0 次插入10393 次删除
  1. 0 17
      node_modules.bak/sha.js/.travis.yml
  2. 0 49
      node_modules.bak/sha.js/LICENSE
  3. 0 44
      node_modules.bak/sha.js/README.md
  4. 0 41
      node_modules.bak/sha.js/bin.js
  5. 0 81
      node_modules.bak/sha.js/hash.js
  6. 0 15
      node_modules.bak/sha.js/index.js
  7. 0 66
      node_modules.bak/sha.js/package.json
  8. 0 94
      node_modules.bak/sha.js/sha.js
  9. 0 99
      node_modules.bak/sha.js/sha1.js
  10. 0 53
      node_modules.bak/sha.js/sha224.js
  11. 0 135
      node_modules.bak/sha.js/sha256.js
  12. 0 57
      node_modules.bak/sha.js/sha384.js
  13. 0 260
      node_modules.bak/sha.js/sha512.js
  14. 0 75
      node_modules.bak/sha.js/test/hash.js
  15. 0 100
      node_modules.bak/sha.js/test/test.js
  16. 0 72
      node_modules.bak/sha.js/test/vectors.js
  17. 0 19
      node_modules.bak/shebang-command/index.js
  18. 0 21
      node_modules.bak/shebang-command/license
  19. 0 71
      node_modules.bak/shebang-command/package.json
  20. 0 39
      node_modules.bak/shebang-command/readme.md
  21. 0 2
      node_modules.bak/shebang-regex/index.js
  22. 0 21
      node_modules.bak/shebang-regex/license
  23. 0 64
      node_modules.bak/shebang-regex/package.json
  24. 0 29
      node_modules.bak/shebang-regex/readme.md
  25. 0 35
      node_modules.bak/signal-exit/CHANGELOG.md
  26. 0 16
      node_modules.bak/signal-exit/LICENSE.txt
  27. 0 39
      node_modules.bak/signal-exit/README.md
  28. 0 163
      node_modules.bak/signal-exit/index.js
  29. 0 66
      node_modules.bak/signal-exit/package.json
  30. 0 53
      node_modules.bak/signal-exit/signals.js
  31. 0 21
      node_modules.bak/snapdragon-node/LICENSE
  32. 0 453
      node_modules.bak/snapdragon-node/README.md
  33. 0 492
      node_modules.bak/snapdragon-node/index.js
  34. 0 109
      node_modules.bak/snapdragon-node/package.json
  35. 0 21
      node_modules.bak/snapdragon-util/LICENSE
  36. 0 807
      node_modules.bak/snapdragon-util/README.md
  37. 0 1019
      node_modules.bak/snapdragon-util/index.js
  38. 0 98
      node_modules.bak/snapdragon-util/package.json
  39. 0 21
      node_modules.bak/snapdragon/LICENSE
  40. 0 321
      node_modules.bak/snapdragon/README.md
  41. 0 174
      node_modules.bak/snapdragon/index.js
  42. 0 177
      node_modules.bak/snapdragon/lib/compiler.js
  43. 0 533
      node_modules.bak/snapdragon/lib/parser.js
  44. 0 14
      node_modules.bak/snapdragon/lib/position.js
  45. 0 145
      node_modules.bak/snapdragon/lib/source-maps.js
  46. 0 48
      node_modules.bak/snapdragon/lib/utils.js
  47. 0 126
      node_modules.bak/snapdragon/package.json
  48. 0 10
      node_modules.bak/sockjs-client/AUTHORS
  49. 0 76
      node_modules.bak/sockjs-client/CODE_OF_CONDUCT.md
  50. 0 327
      node_modules.bak/sockjs-client/Changelog.md
  51. 0 21
      node_modules.bak/sockjs-client/LICENSE
  52. 0 354
      node_modules.bak/sockjs-client/README.md
  53. 0 10
      node_modules.bak/sockjs-client/lib/entry.js
  54. 0 17
      node_modules.bak/sockjs-client/lib/event/close.js
  55. 0 57
      node_modules.bak/sockjs-client/lib/event/emitter.js
  56. 0 22
      node_modules.bak/sockjs-client/lib/event/event.js
  57. 0 62
      node_modules.bak/sockjs-client/lib/event/eventtarget.js
  58. 0 15
      node_modules.bak/sockjs-client/lib/event/trans-message.js
  59. 0 27
      node_modules.bak/sockjs-client/lib/facade.js
  60. 0 102
      node_modules.bak/sockjs-client/lib/iframe-bootstrap.js
  61. 0 49
      node_modules.bak/sockjs-client/lib/info-ajax.js
  62. 0 33
      node_modules.bak/sockjs-client/lib/info-iframe-receiver.js
  63. 0 69
      node_modules.bak/sockjs-client/lib/info-iframe.js
  64. 0 89
      node_modules.bak/sockjs-client/lib/info-receiver.js
  65. 0 10
      node_modules.bak/sockjs-client/lib/location.js
  66. 0 389
      node_modules.bak/sockjs-client/lib/main.js
  67. 0 452
      node_modules.bak/sockjs-client/lib/shims.js
  68. 0 18
      node_modules.bak/sockjs-client/lib/transport-list.js
  69. 0 193
      node_modules.bak/sockjs-client/lib/transport/browser/abstract-xhr.js
  70. 0 1
      node_modules.bak/sockjs-client/lib/transport/browser/eventsource.js
  71. 0 10
      node_modules.bak/sockjs-client/lib/transport/browser/websocket.js
  72. 0 1
      node_modules.bak/sockjs-client/lib/transport/driver/eventsource.js
  73. 0 1
      node_modules.bak/sockjs-client/lib/transport/driver/websocket.js
  74. 0 72
      node_modules.bak/sockjs-client/lib/transport/driver/xhr.js
  75. 0 27
      node_modules.bak/sockjs-client/lib/transport/eventsource.js
  76. 0 25
      node_modules.bak/sockjs-client/lib/transport/htmlfile.js
  77. 0 141
      node_modules.bak/sockjs-client/lib/transport/iframe.js
  78. 0 34
      node_modules.bak/sockjs-client/lib/transport/jsonp-polling.js
  79. 0 49
      node_modules.bak/sockjs-client/lib/transport/lib/ajax-based.js
  80. 0 87
      node_modules.bak/sockjs-client/lib/transport/lib/buffered-sender.js
  81. 0 33
      node_modules.bak/sockjs-client/lib/transport/lib/iframe-wrap.js
  82. 0 57
      node_modules.bak/sockjs-client/lib/transport/lib/polling.js
  83. 0 45
      node_modules.bak/sockjs-client/lib/transport/lib/sender-receiver.js
  84. 0 63
      node_modules.bak/sockjs-client/lib/transport/receiver/eventsource.js
  85. 0 87
      node_modules.bak/sockjs-client/lib/transport/receiver/htmlfile.js
  86. 0 183
      node_modules.bak/sockjs-client/lib/transport/receiver/jsonp.js
  87. 0 70
      node_modules.bak/sockjs-client/lib/transport/receiver/xhr.js
  88. 0 99
      node_modules.bak/sockjs-client/lib/transport/sender/jsonp.js
  89. 0 103
      node_modules.bak/sockjs-client/lib/transport/sender/xdr.js
  90. 0 15
      node_modules.bak/sockjs-client/lib/transport/sender/xhr-cors.js
  91. 0 24
      node_modules.bak/sockjs-client/lib/transport/sender/xhr-fake.js
  92. 0 17
      node_modules.bak/sockjs-client/lib/transport/sender/xhr-local.js
  93. 0 99
      node_modules.bak/sockjs-client/lib/transport/websocket.js
  94. 0 23
      node_modules.bak/sockjs-client/lib/transport/xdr-polling.js
  95. 0 32
      node_modules.bak/sockjs-client/lib/transport/xdr-streaming.js
  96. 0 33
      node_modules.bak/sockjs-client/lib/transport/xhr-polling.js
  97. 0 41
      node_modules.bak/sockjs-client/lib/transport/xhr-streaming.js
  98. 0 17
      node_modules.bak/sockjs-client/lib/utils/browser-crypto.js
  99. 0 27
      node_modules.bak/sockjs-client/lib/utils/browser.js
  100. 0 0
      node_modules.bak/sockjs-client/lib/utils/escape.js

+ 0 - 17
node_modules.bak/sha.js/.travis.yml

@@ -1,17 +0,0 @@
-sudo: false
-os:
-  - linux
-language: node_js
-node_js:
-  - "4"
-  - "5"
-  - "6"
-  - "7"
-env:
-  matrix:
-    - TEST_SUITE=unit
-matrix:
-  include:
-    - node_js: "7"
-      env: TEST_SUITE=lint
-script: npm run $TEST_SUITE

+ 0 - 49
node_modules.bak/sha.js/LICENSE

@@ -1,49 +0,0 @@
-Copyright (c) 2013-2018 sha.js contributors
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in all
-copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-SOFTWARE.
-
-
-Copyright (c) 1998 - 2009, Paul Johnston & Contributors
-All rights reserved.
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions are met:
-
-Redistributions of source code must retain the above copyright notice, this
-list of conditions and the following disclaimer.
-
-Redistributions in binary form must reproduce the above copyright notice, this
-list of conditions and the following disclaimer in the documentation and/or
-other materials provided with the distribution.
-
-Neither the name of the author nor the names of its contributors may be used to
-endorse or promote products derived from this software without specific prior
-written permission.
-
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
-DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
-ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
-LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
-ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
-SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-

+ 0 - 44
node_modules.bak/sha.js/README.md

@@ -1,44 +0,0 @@
-# sha.js
-[![NPM Package](https://img.shields.io/npm/v/sha.js.svg?style=flat-square)](https://www.npmjs.org/package/sha.js)
-[![Build Status](https://img.shields.io/travis/crypto-browserify/sha.js.svg?branch=master&style=flat-square)](https://travis-ci.org/crypto-browserify/sha.js)
-[![Dependency status](https://img.shields.io/david/crypto-browserify/sha.js.svg?style=flat-square)](https://david-dm.org/crypto-browserify/sha.js#info=dependencies)
-
-[![js-standard-style](https://cdn.rawgit.com/feross/standard/master/badge.svg)](https://github.com/feross/standard)
-
-Node style `SHA` on pure JavaScript.
-
-```js
-var shajs = require('sha.js')
-
-console.log(shajs('sha256').update('42').digest('hex'))
-// => 73475cb40a568e8da8a045ced110137e159f890ac4da883b6b17dc651b3a8049
-console.log(new shajs.sha256().update('42').digest('hex'))
-// => 73475cb40a568e8da8a045ced110137e159f890ac4da883b6b17dc651b3a8049
-
-var sha256stream = shajs('sha256')
-sha256stream.end('42')
-console.log(sha256stream.read().toString('hex'))
-// => 73475cb40a568e8da8a045ced110137e159f890ac4da883b6b17dc651b3a8049
-```
-
-## supported hashes
-`sha.js` currently implements:
-
-  - SHA (SHA-0) -- **legacy, do not use in new systems**
-  - SHA-1 -- **legacy, do not use in new systems**
-  - SHA-224
-  - SHA-256
-  - SHA-384
-  - SHA-512
-
-
-## Not an actual stream
-Note, this doesn't actually implement a stream, but wrapping this in a stream is trivial.
-It does update incrementally, so you can hash things larger than RAM, as it uses a constant amount of memory (except when using base64 or utf8 encoding, see code comments).
-
-
-## Acknowledgements
-This work is derived from Paul Johnston's [A JavaScript implementation of the Secure Hash Algorithm](http://pajhome.org.uk/crypt/md5/sha1.html).
-
-
-## LICENSE [MIT](LICENSE)

+ 0 - 41
node_modules.bak/sha.js/bin.js

@@ -1,41 +0,0 @@
-#! /usr/bin/env node
-
-var createHash = require('./browserify')
-var argv = process.argv.slice(2)
-
-function pipe (algorithm, s) {
-  var start = Date.now()
-  var hash = createHash(algorithm || 'sha1')
-
-  s.on('data', function (data) {
-    hash.update(data)
-  })
-
-  s.on('end', function () {
-    if (process.env.DEBUG) {
-      return console.log(hash.digest('hex'), Date.now() - start)
-    }
-
-    console.log(hash.digest('hex'))
-  })
-}
-
-function usage () {
-  console.error('sha.js [algorithm=sha1] [filename] # hash filename with algorithm')
-  console.error('input | sha.js [algorithm=sha1]    # hash stdin with algorithm')
-  console.error('sha.js --help                      # display this message')
-}
-
-if (!process.stdin.isTTY) {
-  pipe(argv[0], process.stdin)
-} else if (argv.length) {
-  if (/--help|-h/.test(argv[0])) {
-    usage()
-  } else {
-    var filename = argv.pop()
-    var algorithm = argv.pop()
-    pipe(algorithm, require('fs').createReadStream(filename))
-  }
-} else {
-  usage()
-}

+ 0 - 81
node_modules.bak/sha.js/hash.js

@@ -1,81 +0,0 @@
-var Buffer = require('safe-buffer').Buffer
-
-// prototype class for hash functions
-function Hash (blockSize, finalSize) {
-  this._block = Buffer.alloc(blockSize)
-  this._finalSize = finalSize
-  this._blockSize = blockSize
-  this._len = 0
-}
-
-Hash.prototype.update = function (data, enc) {
-  if (typeof data === 'string') {
-    enc = enc || 'utf8'
-    data = Buffer.from(data, enc)
-  }
-
-  var block = this._block
-  var blockSize = this._blockSize
-  var length = data.length
-  var accum = this._len
-
-  for (var offset = 0; offset < length;) {
-    var assigned = accum % blockSize
-    var remainder = Math.min(length - offset, blockSize - assigned)
-
-    for (var i = 0; i < remainder; i++) {
-      block[assigned + i] = data[offset + i]
-    }
-
-    accum += remainder
-    offset += remainder
-
-    if ((accum % blockSize) === 0) {
-      this._update(block)
-    }
-  }
-
-  this._len += length
-  return this
-}
-
-Hash.prototype.digest = function (enc) {
-  var rem = this._len % this._blockSize
-
-  this._block[rem] = 0x80
-
-  // zero (rem + 1) trailing bits, where (rem + 1) is the smallest
-  // non-negative solution to the equation (length + 1 + (rem + 1)) === finalSize mod blockSize
-  this._block.fill(0, rem + 1)
-
-  if (rem >= this._finalSize) {
-    this._update(this._block)
-    this._block.fill(0)
-  }
-
-  var bits = this._len * 8
-
-  // uint32
-  if (bits <= 0xffffffff) {
-    this._block.writeUInt32BE(bits, this._blockSize - 4)
-
-  // uint64
-  } else {
-    var lowBits = (bits & 0xffffffff) >>> 0
-    var highBits = (bits - lowBits) / 0x100000000
-
-    this._block.writeUInt32BE(highBits, this._blockSize - 8)
-    this._block.writeUInt32BE(lowBits, this._blockSize - 4)
-  }
-
-  this._update(this._block)
-  var hash = this._hash()
-
-  return enc ? hash.toString(enc) : hash
-}
-
-Hash.prototype._update = function () {
-  throw new Error('_update must be implemented by subclass')
-}
-
-module.exports = Hash

+ 0 - 15
node_modules.bak/sha.js/index.js

@@ -1,15 +0,0 @@
-var exports = module.exports = function SHA (algorithm) {
-  algorithm = algorithm.toLowerCase()
-
-  var Algorithm = exports[algorithm]
-  if (!Algorithm) throw new Error(algorithm + ' is not supported (we accept pull requests)')
-
-  return new Algorithm()
-}
-
-exports.sha = require('./sha')
-exports.sha1 = require('./sha1')
-exports.sha224 = require('./sha224')
-exports.sha256 = require('./sha256')
-exports.sha384 = require('./sha384')
-exports.sha512 = require('./sha512')

+ 0 - 66
node_modules.bak/sha.js/package.json

@@ -1,66 +0,0 @@
-{
-  "_from": "sha.js@^2.4.0",
-  "_id": "sha.js@2.4.11",
-  "_inBundle": false,
-  "_integrity": "sha1-N6XPC4HsvGlD3hCbopYNGyZYSuc=",
-  "_location": "/sha.js",
-  "_phantomChildren": {},
-  "_requested": {
-    "type": "range",
-    "registry": true,
-    "raw": "sha.js@^2.4.0",
-    "name": "sha.js",
-    "escapedName": "sha.js",
-    "rawSpec": "^2.4.0",
-    "saveSpec": null,
-    "fetchSpec": "^2.4.0"
-  },
-  "_requiredBy": [
-    "/create-hash",
-    "/create-hmac",
-    "/pbkdf2"
-  ],
-  "_resolved": "https://registry.npm.taobao.org/sha.js/download/sha.js-2.4.11.tgz",
-  "_shasum": "37a5cf0b81ecbc6943de109ba2960d1b26584ae7",
-  "_spec": "sha.js@^2.4.0",
-  "_where": "D:\\朗通信息\\icssDService\\node_modules\\create-hash",
-  "author": {
-    "name": "Dominic Tarr",
-    "email": "dominic.tarr@gmail.com",
-    "url": "dominictarr.com"
-  },
-  "bin": {
-    "sha.js": "bin.js"
-  },
-  "bugs": {
-    "url": "https://github.com/crypto-browserify/sha.js/issues"
-  },
-  "bundleDependencies": false,
-  "dependencies": {
-    "inherits": "^2.0.1",
-    "safe-buffer": "^5.0.1"
-  },
-  "deprecated": false,
-  "description": "Streamable SHA hashes in pure javascript",
-  "devDependencies": {
-    "buffer": "~2.3.2",
-    "hash-test-vectors": "^1.3.1",
-    "standard": "^10.0.2",
-    "tape": "~2.3.2",
-    "typedarray": "0.0.6"
-  },
-  "homepage": "https://github.com/crypto-browserify/sha.js",
-  "license": "(MIT AND BSD-3-Clause)",
-  "name": "sha.js",
-  "repository": {
-    "type": "git",
-    "url": "git://github.com/crypto-browserify/sha.js.git"
-  },
-  "scripts": {
-    "lint": "standard",
-    "prepublish": "npm ls && npm run unit",
-    "test": "npm run lint && npm run unit",
-    "unit": "set -e; for t in test/*.js; do node $t; done;"
-  },
-  "version": "2.4.11"
-}

+ 0 - 94
node_modules.bak/sha.js/sha.js

@@ -1,94 +0,0 @@
-/*
- * A JavaScript implementation of the Secure Hash Algorithm, SHA-0, as defined
- * in FIPS PUB 180-1
- * This source code is derived from sha1.js of the same repository.
- * The difference between SHA-0 and SHA-1 is just a bitwise rotate left
- * operation was added.
- */
-
-var inherits = require('inherits')
-var Hash = require('./hash')
-var Buffer = require('safe-buffer').Buffer
-
-var K = [
-  0x5a827999, 0x6ed9eba1, 0x8f1bbcdc | 0, 0xca62c1d6 | 0
-]
-
-var W = new Array(80)
-
-function Sha () {
-  this.init()
-  this._w = W
-
-  Hash.call(this, 64, 56)
-}
-
-inherits(Sha, Hash)
-
-Sha.prototype.init = function () {
-  this._a = 0x67452301
-  this._b = 0xefcdab89
-  this._c = 0x98badcfe
-  this._d = 0x10325476
-  this._e = 0xc3d2e1f0
-
-  return this
-}
-
-function rotl5 (num) {
-  return (num << 5) | (num >>> 27)
-}
-
-function rotl30 (num) {
-  return (num << 30) | (num >>> 2)
-}
-
-function ft (s, b, c, d) {
-  if (s === 0) return (b & c) | ((~b) & d)
-  if (s === 2) return (b & c) | (b & d) | (c & d)
-  return b ^ c ^ d
-}
-
-Sha.prototype._update = function (M) {
-  var W = this._w
-
-  var a = this._a | 0
-  var b = this._b | 0
-  var c = this._c | 0
-  var d = this._d | 0
-  var e = this._e | 0
-
-  for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4)
-  for (; i < 80; ++i) W[i] = W[i - 3] ^ W[i - 8] ^ W[i - 14] ^ W[i - 16]
-
-  for (var j = 0; j < 80; ++j) {
-    var s = ~~(j / 20)
-    var t = (rotl5(a) + ft(s, b, c, d) + e + W[j] + K[s]) | 0
-
-    e = d
-    d = c
-    c = rotl30(b)
-    b = a
-    a = t
-  }
-
-  this._a = (a + this._a) | 0
-  this._b = (b + this._b) | 0
-  this._c = (c + this._c) | 0
-  this._d = (d + this._d) | 0
-  this._e = (e + this._e) | 0
-}
-
-Sha.prototype._hash = function () {
-  var H = Buffer.allocUnsafe(20)
-
-  H.writeInt32BE(this._a | 0, 0)
-  H.writeInt32BE(this._b | 0, 4)
-  H.writeInt32BE(this._c | 0, 8)
-  H.writeInt32BE(this._d | 0, 12)
-  H.writeInt32BE(this._e | 0, 16)
-
-  return H
-}
-
-module.exports = Sha

+ 0 - 99
node_modules.bak/sha.js/sha1.js

@@ -1,99 +0,0 @@
-/*
- * A JavaScript implementation of the Secure Hash Algorithm, SHA-1, as defined
- * in FIPS PUB 180-1
- * Version 2.1a Copyright Paul Johnston 2000 - 2002.
- * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet
- * Distributed under the BSD License
- * See http://pajhome.org.uk/crypt/md5 for details.
- */
-
-var inherits = require('inherits')
-var Hash = require('./hash')
-var Buffer = require('safe-buffer').Buffer
-
-var K = [
-  0x5a827999, 0x6ed9eba1, 0x8f1bbcdc | 0, 0xca62c1d6 | 0
-]
-
-var W = new Array(80)
-
-function Sha1 () {
-  this.init()
-  this._w = W
-
-  Hash.call(this, 64, 56)
-}
-
-inherits(Sha1, Hash)
-
-Sha1.prototype.init = function () {
-  this._a = 0x67452301
-  this._b = 0xefcdab89
-  this._c = 0x98badcfe
-  this._d = 0x10325476
-  this._e = 0xc3d2e1f0
-
-  return this
-}
-
-function rotl1 (num) {
-  return (num << 1) | (num >>> 31)
-}
-
-function rotl5 (num) {
-  return (num << 5) | (num >>> 27)
-}
-
-function rotl30 (num) {
-  return (num << 30) | (num >>> 2)
-}
-
-function ft (s, b, c, d) {
-  if (s === 0) return (b & c) | ((~b) & d)
-  if (s === 2) return (b & c) | (b & d) | (c & d)
-  return b ^ c ^ d
-}
-
-Sha1.prototype._update = function (M) {
-  var W = this._w
-
-  var a = this._a | 0
-  var b = this._b | 0
-  var c = this._c | 0
-  var d = this._d | 0
-  var e = this._e | 0
-
-  for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4)
-  for (; i < 80; ++i) W[i] = rotl1(W[i - 3] ^ W[i - 8] ^ W[i - 14] ^ W[i - 16])
-
-  for (var j = 0; j < 80; ++j) {
-    var s = ~~(j / 20)
-    var t = (rotl5(a) + ft(s, b, c, d) + e + W[j] + K[s]) | 0
-
-    e = d
-    d = c
-    c = rotl30(b)
-    b = a
-    a = t
-  }
-
-  this._a = (a + this._a) | 0
-  this._b = (b + this._b) | 0
-  this._c = (c + this._c) | 0
-  this._d = (d + this._d) | 0
-  this._e = (e + this._e) | 0
-}
-
-Sha1.prototype._hash = function () {
-  var H = Buffer.allocUnsafe(20)
-
-  H.writeInt32BE(this._a | 0, 0)
-  H.writeInt32BE(this._b | 0, 4)
-  H.writeInt32BE(this._c | 0, 8)
-  H.writeInt32BE(this._d | 0, 12)
-  H.writeInt32BE(this._e | 0, 16)
-
-  return H
-}
-
-module.exports = Sha1

+ 0 - 53
node_modules.bak/sha.js/sha224.js

@@ -1,53 +0,0 @@
-/**
- * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined
- * in FIPS 180-2
- * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009.
- * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet
- *
- */
-
-var inherits = require('inherits')
-var Sha256 = require('./sha256')
-var Hash = require('./hash')
-var Buffer = require('safe-buffer').Buffer
-
-var W = new Array(64)
-
-function Sha224 () {
-  this.init()
-
-  this._w = W // new Array(64)
-
-  Hash.call(this, 64, 56)
-}
-
-inherits(Sha224, Sha256)
-
-Sha224.prototype.init = function () {
-  this._a = 0xc1059ed8
-  this._b = 0x367cd507
-  this._c = 0x3070dd17
-  this._d = 0xf70e5939
-  this._e = 0xffc00b31
-  this._f = 0x68581511
-  this._g = 0x64f98fa7
-  this._h = 0xbefa4fa4
-
-  return this
-}
-
-Sha224.prototype._hash = function () {
-  var H = Buffer.allocUnsafe(28)
-
-  H.writeInt32BE(this._a, 0)
-  H.writeInt32BE(this._b, 4)
-  H.writeInt32BE(this._c, 8)
-  H.writeInt32BE(this._d, 12)
-  H.writeInt32BE(this._e, 16)
-  H.writeInt32BE(this._f, 20)
-  H.writeInt32BE(this._g, 24)
-
-  return H
-}
-
-module.exports = Sha224

+ 0 - 135
node_modules.bak/sha.js/sha256.js

@@ -1,135 +0,0 @@
-/**
- * A JavaScript implementation of the Secure Hash Algorithm, SHA-256, as defined
- * in FIPS 180-2
- * Version 2.2-beta Copyright Angel Marin, Paul Johnston 2000 - 2009.
- * Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet
- *
- */
-
-var inherits = require('inherits')
-var Hash = require('./hash')
-var Buffer = require('safe-buffer').Buffer
-
-var K = [
-  0x428A2F98, 0x71374491, 0xB5C0FBCF, 0xE9B5DBA5,
-  0x3956C25B, 0x59F111F1, 0x923F82A4, 0xAB1C5ED5,
-  0xD807AA98, 0x12835B01, 0x243185BE, 0x550C7DC3,
-  0x72BE5D74, 0x80DEB1FE, 0x9BDC06A7, 0xC19BF174,
-  0xE49B69C1, 0xEFBE4786, 0x0FC19DC6, 0x240CA1CC,
-  0x2DE92C6F, 0x4A7484AA, 0x5CB0A9DC, 0x76F988DA,
-  0x983E5152, 0xA831C66D, 0xB00327C8, 0xBF597FC7,
-  0xC6E00BF3, 0xD5A79147, 0x06CA6351, 0x14292967,
-  0x27B70A85, 0x2E1B2138, 0x4D2C6DFC, 0x53380D13,
-  0x650A7354, 0x766A0ABB, 0x81C2C92E, 0x92722C85,
-  0xA2BFE8A1, 0xA81A664B, 0xC24B8B70, 0xC76C51A3,
-  0xD192E819, 0xD6990624, 0xF40E3585, 0x106AA070,
-  0x19A4C116, 0x1E376C08, 0x2748774C, 0x34B0BCB5,
-  0x391C0CB3, 0x4ED8AA4A, 0x5B9CCA4F, 0x682E6FF3,
-  0x748F82EE, 0x78A5636F, 0x84C87814, 0x8CC70208,
-  0x90BEFFFA, 0xA4506CEB, 0xBEF9A3F7, 0xC67178F2
-]
-
-var W = new Array(64)
-
-function Sha256 () {
-  this.init()
-
-  this._w = W // new Array(64)
-
-  Hash.call(this, 64, 56)
-}
-
-inherits(Sha256, Hash)
-
-Sha256.prototype.init = function () {
-  this._a = 0x6a09e667
-  this._b = 0xbb67ae85
-  this._c = 0x3c6ef372
-  this._d = 0xa54ff53a
-  this._e = 0x510e527f
-  this._f = 0x9b05688c
-  this._g = 0x1f83d9ab
-  this._h = 0x5be0cd19
-
-  return this
-}
-
-function ch (x, y, z) {
-  return z ^ (x & (y ^ z))
-}
-
-function maj (x, y, z) {
-  return (x & y) | (z & (x | y))
-}
-
-function sigma0 (x) {
-  return (x >>> 2 | x << 30) ^ (x >>> 13 | x << 19) ^ (x >>> 22 | x << 10)
-}
-
-function sigma1 (x) {
-  return (x >>> 6 | x << 26) ^ (x >>> 11 | x << 21) ^ (x >>> 25 | x << 7)
-}
-
-function gamma0 (x) {
-  return (x >>> 7 | x << 25) ^ (x >>> 18 | x << 14) ^ (x >>> 3)
-}
-
-function gamma1 (x) {
-  return (x >>> 17 | x << 15) ^ (x >>> 19 | x << 13) ^ (x >>> 10)
-}
-
-Sha256.prototype._update = function (M) {
-  var W = this._w
-
-  var a = this._a | 0
-  var b = this._b | 0
-  var c = this._c | 0
-  var d = this._d | 0
-  var e = this._e | 0
-  var f = this._f | 0
-  var g = this._g | 0
-  var h = this._h | 0
-
-  for (var i = 0; i < 16; ++i) W[i] = M.readInt32BE(i * 4)
-  for (; i < 64; ++i) W[i] = (gamma1(W[i - 2]) + W[i - 7] + gamma0(W[i - 15]) + W[i - 16]) | 0
-
-  for (var j = 0; j < 64; ++j) {
-    var T1 = (h + sigma1(e) + ch(e, f, g) + K[j] + W[j]) | 0
-    var T2 = (sigma0(a) + maj(a, b, c)) | 0
-
-    h = g
-    g = f
-    f = e
-    e = (d + T1) | 0
-    d = c
-    c = b
-    b = a
-    a = (T1 + T2) | 0
-  }
-
-  this._a = (a + this._a) | 0
-  this._b = (b + this._b) | 0
-  this._c = (c + this._c) | 0
-  this._d = (d + this._d) | 0
-  this._e = (e + this._e) | 0
-  this._f = (f + this._f) | 0
-  this._g = (g + this._g) | 0
-  this._h = (h + this._h) | 0
-}
-
-Sha256.prototype._hash = function () {
-  var H = Buffer.allocUnsafe(32)
-
-  H.writeInt32BE(this._a, 0)
-  H.writeInt32BE(this._b, 4)
-  H.writeInt32BE(this._c, 8)
-  H.writeInt32BE(this._d, 12)
-  H.writeInt32BE(this._e, 16)
-  H.writeInt32BE(this._f, 20)
-  H.writeInt32BE(this._g, 24)
-  H.writeInt32BE(this._h, 28)
-
-  return H
-}
-
-module.exports = Sha256

+ 0 - 57
node_modules.bak/sha.js/sha384.js

@@ -1,57 +0,0 @@
-var inherits = require('inherits')
-var SHA512 = require('./sha512')
-var Hash = require('./hash')
-var Buffer = require('safe-buffer').Buffer
-
-var W = new Array(160)
-
-function Sha384 () {
-  this.init()
-  this._w = W
-
-  Hash.call(this, 128, 112)
-}
-
-inherits(Sha384, SHA512)
-
-Sha384.prototype.init = function () {
-  this._ah = 0xcbbb9d5d
-  this._bh = 0x629a292a
-  this._ch = 0x9159015a
-  this._dh = 0x152fecd8
-  this._eh = 0x67332667
-  this._fh = 0x8eb44a87
-  this._gh = 0xdb0c2e0d
-  this._hh = 0x47b5481d
-
-  this._al = 0xc1059ed8
-  this._bl = 0x367cd507
-  this._cl = 0x3070dd17
-  this._dl = 0xf70e5939
-  this._el = 0xffc00b31
-  this._fl = 0x68581511
-  this._gl = 0x64f98fa7
-  this._hl = 0xbefa4fa4
-
-  return this
-}
-
-Sha384.prototype._hash = function () {
-  var H = Buffer.allocUnsafe(48)
-
-  function writeInt64BE (h, l, offset) {
-    H.writeInt32BE(h, offset)
-    H.writeInt32BE(l, offset + 4)
-  }
-
-  writeInt64BE(this._ah, this._al, 0)
-  writeInt64BE(this._bh, this._bl, 8)
-  writeInt64BE(this._ch, this._cl, 16)
-  writeInt64BE(this._dh, this._dl, 24)
-  writeInt64BE(this._eh, this._el, 32)
-  writeInt64BE(this._fh, this._fl, 40)
-
-  return H
-}
-
-module.exports = Sha384

+ 0 - 260
node_modules.bak/sha.js/sha512.js

@@ -1,260 +0,0 @@
-var inherits = require('inherits')
-var Hash = require('./hash')
-var Buffer = require('safe-buffer').Buffer
-
-var K = [
-  0x428a2f98, 0xd728ae22, 0x71374491, 0x23ef65cd,
-  0xb5c0fbcf, 0xec4d3b2f, 0xe9b5dba5, 0x8189dbbc,
-  0x3956c25b, 0xf348b538, 0x59f111f1, 0xb605d019,
-  0x923f82a4, 0xaf194f9b, 0xab1c5ed5, 0xda6d8118,
-  0xd807aa98, 0xa3030242, 0x12835b01, 0x45706fbe,
-  0x243185be, 0x4ee4b28c, 0x550c7dc3, 0xd5ffb4e2,
-  0x72be5d74, 0xf27b896f, 0x80deb1fe, 0x3b1696b1,
-  0x9bdc06a7, 0x25c71235, 0xc19bf174, 0xcf692694,
-  0xe49b69c1, 0x9ef14ad2, 0xefbe4786, 0x384f25e3,
-  0x0fc19dc6, 0x8b8cd5b5, 0x240ca1cc, 0x77ac9c65,
-  0x2de92c6f, 0x592b0275, 0x4a7484aa, 0x6ea6e483,
-  0x5cb0a9dc, 0xbd41fbd4, 0x76f988da, 0x831153b5,
-  0x983e5152, 0xee66dfab, 0xa831c66d, 0x2db43210,
-  0xb00327c8, 0x98fb213f, 0xbf597fc7, 0xbeef0ee4,
-  0xc6e00bf3, 0x3da88fc2, 0xd5a79147, 0x930aa725,
-  0x06ca6351, 0xe003826f, 0x14292967, 0x0a0e6e70,
-  0x27b70a85, 0x46d22ffc, 0x2e1b2138, 0x5c26c926,
-  0x4d2c6dfc, 0x5ac42aed, 0x53380d13, 0x9d95b3df,
-  0x650a7354, 0x8baf63de, 0x766a0abb, 0x3c77b2a8,
-  0x81c2c92e, 0x47edaee6, 0x92722c85, 0x1482353b,
-  0xa2bfe8a1, 0x4cf10364, 0xa81a664b, 0xbc423001,
-  0xc24b8b70, 0xd0f89791, 0xc76c51a3, 0x0654be30,
-  0xd192e819, 0xd6ef5218, 0xd6990624, 0x5565a910,
-  0xf40e3585, 0x5771202a, 0x106aa070, 0x32bbd1b8,
-  0x19a4c116, 0xb8d2d0c8, 0x1e376c08, 0x5141ab53,
-  0x2748774c, 0xdf8eeb99, 0x34b0bcb5, 0xe19b48a8,
-  0x391c0cb3, 0xc5c95a63, 0x4ed8aa4a, 0xe3418acb,
-  0x5b9cca4f, 0x7763e373, 0x682e6ff3, 0xd6b2b8a3,
-  0x748f82ee, 0x5defb2fc, 0x78a5636f, 0x43172f60,
-  0x84c87814, 0xa1f0ab72, 0x8cc70208, 0x1a6439ec,
-  0x90befffa, 0x23631e28, 0xa4506ceb, 0xde82bde9,
-  0xbef9a3f7, 0xb2c67915, 0xc67178f2, 0xe372532b,
-  0xca273ece, 0xea26619c, 0xd186b8c7, 0x21c0c207,
-  0xeada7dd6, 0xcde0eb1e, 0xf57d4f7f, 0xee6ed178,
-  0x06f067aa, 0x72176fba, 0x0a637dc5, 0xa2c898a6,
-  0x113f9804, 0xbef90dae, 0x1b710b35, 0x131c471b,
-  0x28db77f5, 0x23047d84, 0x32caab7b, 0x40c72493,
-  0x3c9ebe0a, 0x15c9bebc, 0x431d67c4, 0x9c100d4c,
-  0x4cc5d4be, 0xcb3e42b6, 0x597f299c, 0xfc657e2a,
-  0x5fcb6fab, 0x3ad6faec, 0x6c44198c, 0x4a475817
-]
-
-var W = new Array(160)
-
-function Sha512 () {
-  this.init()
-  this._w = W
-
-  Hash.call(this, 128, 112)
-}
-
-inherits(Sha512, Hash)
-
-Sha512.prototype.init = function () {
-  this._ah = 0x6a09e667
-  this._bh = 0xbb67ae85
-  this._ch = 0x3c6ef372
-  this._dh = 0xa54ff53a
-  this._eh = 0x510e527f
-  this._fh = 0x9b05688c
-  this._gh = 0x1f83d9ab
-  this._hh = 0x5be0cd19
-
-  this._al = 0xf3bcc908
-  this._bl = 0x84caa73b
-  this._cl = 0xfe94f82b
-  this._dl = 0x5f1d36f1
-  this._el = 0xade682d1
-  this._fl = 0x2b3e6c1f
-  this._gl = 0xfb41bd6b
-  this._hl = 0x137e2179
-
-  return this
-}
-
-function Ch (x, y, z) {
-  return z ^ (x & (y ^ z))
-}
-
-function maj (x, y, z) {
-  return (x & y) | (z & (x | y))
-}
-
-function sigma0 (x, xl) {
-  return (x >>> 28 | xl << 4) ^ (xl >>> 2 | x << 30) ^ (xl >>> 7 | x << 25)
-}
-
-function sigma1 (x, xl) {
-  return (x >>> 14 | xl << 18) ^ (x >>> 18 | xl << 14) ^ (xl >>> 9 | x << 23)
-}
-
-function Gamma0 (x, xl) {
-  return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7)
-}
-
-function Gamma0l (x, xl) {
-  return (x >>> 1 | xl << 31) ^ (x >>> 8 | xl << 24) ^ (x >>> 7 | xl << 25)
-}
-
-function Gamma1 (x, xl) {
-  return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6)
-}
-
-function Gamma1l (x, xl) {
-  return (x >>> 19 | xl << 13) ^ (xl >>> 29 | x << 3) ^ (x >>> 6 | xl << 26)
-}
-
-function getCarry (a, b) {
-  return (a >>> 0) < (b >>> 0) ? 1 : 0
-}
-
-Sha512.prototype._update = function (M) {
-  var W = this._w
-
-  var ah = this._ah | 0
-  var bh = this._bh | 0
-  var ch = this._ch | 0
-  var dh = this._dh | 0
-  var eh = this._eh | 0
-  var fh = this._fh | 0
-  var gh = this._gh | 0
-  var hh = this._hh | 0
-
-  var al = this._al | 0
-  var bl = this._bl | 0
-  var cl = this._cl | 0
-  var dl = this._dl | 0
-  var el = this._el | 0
-  var fl = this._fl | 0
-  var gl = this._gl | 0
-  var hl = this._hl | 0
-
-  for (var i = 0; i < 32; i += 2) {
-    W[i] = M.readInt32BE(i * 4)
-    W[i + 1] = M.readInt32BE(i * 4 + 4)
-  }
-  for (; i < 160; i += 2) {
-    var xh = W[i - 15 * 2]
-    var xl = W[i - 15 * 2 + 1]
-    var gamma0 = Gamma0(xh, xl)
-    var gamma0l = Gamma0l(xl, xh)
-
-    xh = W[i - 2 * 2]
-    xl = W[i - 2 * 2 + 1]
-    var gamma1 = Gamma1(xh, xl)
-    var gamma1l = Gamma1l(xl, xh)
-
-    // W[i] = gamma0 + W[i - 7] + gamma1 + W[i - 16]
-    var Wi7h = W[i - 7 * 2]
-    var Wi7l = W[i - 7 * 2 + 1]
-
-    var Wi16h = W[i - 16 * 2]
-    var Wi16l = W[i - 16 * 2 + 1]
-
-    var Wil = (gamma0l + Wi7l) | 0
-    var Wih = (gamma0 + Wi7h + getCarry(Wil, gamma0l)) | 0
-    Wil = (Wil + gamma1l) | 0
-    Wih = (Wih + gamma1 + getCarry(Wil, gamma1l)) | 0
-    Wil = (Wil + Wi16l) | 0
-    Wih = (Wih + Wi16h + getCarry(Wil, Wi16l)) | 0
-
-    W[i] = Wih
-    W[i + 1] = Wil
-  }
-
-  for (var j = 0; j < 160; j += 2) {
-    Wih = W[j]
-    Wil = W[j + 1]
-
-    var majh = maj(ah, bh, ch)
-    var majl = maj(al, bl, cl)
-
-    var sigma0h = sigma0(ah, al)
-    var sigma0l = sigma0(al, ah)
-    var sigma1h = sigma1(eh, el)
-    var sigma1l = sigma1(el, eh)
-
-    // t1 = h + sigma1 + ch + K[j] + W[j]
-    var Kih = K[j]
-    var Kil = K[j + 1]
-
-    var chh = Ch(eh, fh, gh)
-    var chl = Ch(el, fl, gl)
-
-    var t1l = (hl + sigma1l) | 0
-    var t1h = (hh + sigma1h + getCarry(t1l, hl)) | 0
-    t1l = (t1l + chl) | 0
-    t1h = (t1h + chh + getCarry(t1l, chl)) | 0
-    t1l = (t1l + Kil) | 0
-    t1h = (t1h + Kih + getCarry(t1l, Kil)) | 0
-    t1l = (t1l + Wil) | 0
-    t1h = (t1h + Wih + getCarry(t1l, Wil)) | 0
-
-    // t2 = sigma0 + maj
-    var t2l = (sigma0l + majl) | 0
-    var t2h = (sigma0h + majh + getCarry(t2l, sigma0l)) | 0
-
-    hh = gh
-    hl = gl
-    gh = fh
-    gl = fl
-    fh = eh
-    fl = el
-    el = (dl + t1l) | 0
-    eh = (dh + t1h + getCarry(el, dl)) | 0
-    dh = ch
-    dl = cl
-    ch = bh
-    cl = bl
-    bh = ah
-    bl = al
-    al = (t1l + t2l) | 0
-    ah = (t1h + t2h + getCarry(al, t1l)) | 0
-  }
-
-  this._al = (this._al + al) | 0
-  this._bl = (this._bl + bl) | 0
-  this._cl = (this._cl + cl) | 0
-  this._dl = (this._dl + dl) | 0
-  this._el = (this._el + el) | 0
-  this._fl = (this._fl + fl) | 0
-  this._gl = (this._gl + gl) | 0
-  this._hl = (this._hl + hl) | 0
-
-  this._ah = (this._ah + ah + getCarry(this._al, al)) | 0
-  this._bh = (this._bh + bh + getCarry(this._bl, bl)) | 0
-  this._ch = (this._ch + ch + getCarry(this._cl, cl)) | 0
-  this._dh = (this._dh + dh + getCarry(this._dl, dl)) | 0
-  this._eh = (this._eh + eh + getCarry(this._el, el)) | 0
-  this._fh = (this._fh + fh + getCarry(this._fl, fl)) | 0
-  this._gh = (this._gh + gh + getCarry(this._gl, gl)) | 0
-  this._hh = (this._hh + hh + getCarry(this._hl, hl)) | 0
-}
-
-Sha512.prototype._hash = function () {
-  var H = Buffer.allocUnsafe(64)
-
-  function writeInt64BE (h, l, offset) {
-    H.writeInt32BE(h, offset)
-    H.writeInt32BE(l, offset + 4)
-  }
-
-  writeInt64BE(this._ah, this._al, 0)
-  writeInt64BE(this._bh, this._bl, 8)
-  writeInt64BE(this._ch, this._cl, 16)
-  writeInt64BE(this._dh, this._dl, 24)
-  writeInt64BE(this._eh, this._el, 32)
-  writeInt64BE(this._fh, this._fl, 40)
-  writeInt64BE(this._gh, this._gl, 48)
-  writeInt64BE(this._hh, this._hl, 56)
-
-  return H
-}
-
-module.exports = Sha512

+ 0 - 75
node_modules.bak/sha.js/test/hash.js

@@ -1,75 +0,0 @@
-var tape = require('tape')
-var Hash = require('../hash')
-var hex = '0A1B2C3D4E5F6G7H'
-
-function equal (t, a, b) {
-  t.equal(a.length, b.length)
-  t.equal(a.toString('hex'), b.toString('hex'))
-}
-
-var hexBuf = Buffer.from('0A1B2C3D4E5F6G7H', 'utf8')
-var count16 = {
-  strings: ['0A1B2C3D4E5F6G7H'],
-  buffers: [
-    hexBuf,
-    Buffer.from('80000000000000000000000000000080', 'hex')
-  ]
-}
-
-var empty = {
-  strings: [''],
-  buffers: [
-    Buffer.from('80000000000000000000000000000000', 'hex')
-  ]
-}
-
-var multi = {
-  strings: ['abcd', 'efhijk', 'lmnopq'],
-  buffers: [
-    Buffer.from('abcdefhijklmnopq', 'ascii'),
-    Buffer.from('80000000000000000000000000000080', 'hex')
-  ]
-}
-
-var long = {
-  strings: [hex + hex],
-  buffers: [
-    hexBuf,
-    hexBuf,
-    Buffer.from('80000000000000000000000000000100', 'hex')
-  ]
-}
-
-function makeTest (name, data) {
-  tape(name, function (t) {
-    var h = new Hash(16, 8)
-    var hash = Buffer.alloc(20)
-    var n = 2
-    var expected = data.buffers.slice()
-    // t.plan(expected.length + 1)
-
-    h._update = function (block) {
-      var e = expected.shift()
-      equal(t, block, e)
-
-      if (n < 0) {
-        throw new Error('expecting only 2 calls to _update')
-      }
-    }
-    h._hash = function () {
-      return hash
-    }
-
-    data.strings.forEach(function (string) {
-      h.update(string, 'ascii')
-    })
-
-    equal(t, h.digest(), hash)
-    t.end()
-  })
-}
-
-makeTest('Hash#update 1 in 1', count16)
-makeTest('empty Hash#update', empty)
-makeTest('Hash#update 1 in 3', multi)
-makeTest('Hash#update 2 in 1', long)

+ 0 - 100
node_modules.bak/sha.js/test/test.js

@@ -1,100 +0,0 @@
-var crypto = require('crypto')
-var tape = require('tape')
-var Sha1 = require('../').sha1
-
-var inputs = [
-  ['', 'ascii'],
-  ['abc', 'ascii'],
-  ['123', 'ascii'],
-  ['123456789abcdef123456789abcdef123456789abcdef123456789abcdef', 'ascii'],
-  ['123456789abcdef123456789abcdef123456789abcdef123456789abc', 'ascii'],
-  ['123456789abcdef123456789abcdef123456789abcdef123456789ab', 'ascii'],
-  ['0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcde', 'ascii'],
-  ['0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef', 'ascii'],
-  ['foobarbaz', 'ascii']
-]
-
-tape("hash is the same as node's crypto", function (t) {
-  inputs.forEach(function (v) {
-    var a = new Sha1().update(v[0], v[1]).digest('hex')
-    var e = crypto.createHash('sha1').update(v[0], v[1]).digest('hex')
-    console.log(a, '==', e)
-    t.equal(a, e)
-  })
-
-  t.end()
-})
-
-tape('call update multiple times', function (t) {
-  inputs.forEach(function (v) {
-    var hash = new Sha1()
-    var _hash = crypto.createHash('sha1')
-
-    for (var i = 0; i < v[0].length; i = (i + 1) * 2) {
-      var s = v[0].substring(i, (i + 1) * 2)
-      hash.update(s, v[1])
-      _hash.update(s, v[1])
-    }
-
-    var a = hash.digest('hex')
-    var e = _hash.digest('hex')
-    console.log(a, '==', e)
-    t.equal(a, e)
-  })
-  t.end()
-})
-
-tape('call update twice', function (t) {
-  var _hash = crypto.createHash('sha1')
-  var hash = new Sha1()
-
-  _hash.update('foo', 'ascii')
-  hash.update('foo', 'ascii')
-
-  _hash.update('bar', 'ascii')
-  hash.update('bar', 'ascii')
-
-  _hash.update('baz', 'ascii')
-  hash.update('baz', 'ascii')
-
-  var a = hash.digest('hex')
-  var e = _hash.digest('hex')
-
-  t.equal(a, e)
-  t.end()
-})
-
-tape('hex encoding', function (t) {
-  inputs.forEach(function (v) {
-    var hash = new Sha1()
-    var _hash = crypto.createHash('sha1')
-
-    for (var i = 0; i < v[0].length; i = (i + 1) * 2) {
-      var s = v[0].substring(i, (i + 1) * 2)
-      hash.update(Buffer.from(s, 'ascii').toString('hex'), 'hex')
-      _hash.update(Buffer.from(s, 'ascii').toString('hex'), 'hex')
-    }
-    var a = hash.digest('hex')
-    var e = _hash.digest('hex')
-
-    console.log(a, '==', e)
-    t.equal(a, e)
-  })
-
-  t.end()
-})
-
-tape('call digest for more than MAX_UINT32 bits of data', function (t) {
-  var _hash = crypto.createHash('sha1')
-  var hash = new Sha1()
-  var bigData = Buffer.alloc(0x1ffffffff / 8)
-
-  hash.update(bigData)
-  _hash.update(bigData)
-
-  var a = hash.digest('hex')
-  var e = _hash.digest('hex')
-
-  t.equal(a, e)
-  t.end()
-})

+ 0 - 72
node_modules.bak/sha.js/test/vectors.js

@@ -1,72 +0,0 @@
-var tape = require('tape')
-var vectors = require('hash-test-vectors')
-// var from = require('bops/typedarray/from')
-var Buffer = require('safe-buffer').Buffer
-
-var createHash = require('../')
-
-function makeTest (alg, i, verbose) {
-  var v = vectors[i]
-
-  tape(alg + ': NIST vector ' + i, function (t) {
-    if (verbose) {
-      console.log(v)
-      console.log('VECTOR', i)
-      console.log('INPUT', v.input)
-      console.log(Buffer.from(v.input, 'base64').toString('hex'))
-    }
-
-    var buf = Buffer.from(v.input, 'base64')
-    t.equal(createHash(alg).update(buf).digest('hex'), v[alg])
-
-    i = ~~(buf.length / 2)
-    var buf1 = buf.slice(0, i)
-    var buf2 = buf.slice(i, buf.length)
-
-    console.log(buf1.length, buf2.length, buf.length)
-    console.log(createHash(alg)._block.length)
-
-    t.equal(
-      createHash(alg)
-        .update(buf1)
-        .update(buf2)
-        .digest('hex'),
-      v[alg]
-    )
-
-    var j, buf3
-
-    i = ~~(buf.length / 3)
-    j = ~~(buf.length * 2 / 3)
-    buf1 = buf.slice(0, i)
-    buf2 = buf.slice(i, j)
-    buf3 = buf.slice(j, buf.length)
-
-    t.equal(
-      createHash(alg)
-        .update(buf1)
-        .update(buf2)
-        .update(buf3)
-        .digest('hex'),
-      v[alg]
-    )
-
-    setTimeout(function () {
-      // avoid "too much recursion" errors in tape in firefox
-      t.end()
-    })
-  })
-}
-
-if (process.argv[2]) {
-  makeTest(process.argv[2], parseInt(process.argv[3], 10), true)
-} else {
-  vectors.forEach(function (v, i) {
-    makeTest('sha', i)
-    makeTest('sha1', i)
-    makeTest('sha224', i)
-    makeTest('sha256', i)
-    makeTest('sha384', i)
-    makeTest('sha512', i)
-  })
-}

+ 0 - 19
node_modules.bak/shebang-command/index.js

@@ -1,19 +0,0 @@
-'use strict';
-var shebangRegex = require('shebang-regex');
-
-module.exports = function (str) {
-	var match = str.match(shebangRegex);
-
-	if (!match) {
-		return null;
-	}
-
-	var arr = match[0].replace(/#! ?/, '').split(' ');
-	var bin = arr[0].split('/').pop();
-	var arg = arr[1];
-
-	return (bin === 'env' ?
-		arg :
-		bin + (arg ? ' ' + arg : '')
-	);
-};

+ 0 - 21
node_modules.bak/shebang-command/license

@@ -1,21 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) Kevin Martensson <kevinmartensson@gmail.com> (github.com/kevva)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.

+ 0 - 71
node_modules.bak/shebang-command/package.json

@@ -1,71 +0,0 @@
-{
-  "_from": "shebang-command@^1.2.0",
-  "_id": "shebang-command@1.2.0",
-  "_inBundle": false,
-  "_integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=",
-  "_location": "/shebang-command",
-  "_phantomChildren": {},
-  "_requested": {
-    "type": "range",
-    "registry": true,
-    "raw": "shebang-command@^1.2.0",
-    "name": "shebang-command",
-    "escapedName": "shebang-command",
-    "rawSpec": "^1.2.0",
-    "saveSpec": null,
-    "fetchSpec": "^1.2.0"
-  },
-  "_requiredBy": [
-    "/cross-spawn"
-  ],
-  "_resolved": "https://registry.npm.taobao.org/shebang-command/download/shebang-command-1.2.0.tgz?cache=0&sync_timestamp=1567781622888&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fshebang-command%2Fdownload%2Fshebang-command-1.2.0.tgz",
-  "_shasum": "44aac65b695b03398968c39f363fee5deafdf1ea",
-  "_spec": "shebang-command@^1.2.0",
-  "_where": "D:\\朗通信息\\icssDService\\node_modules\\cross-spawn",
-  "author": {
-    "name": "Kevin Martensson",
-    "email": "kevinmartensson@gmail.com",
-    "url": "github.com/kevva"
-  },
-  "bugs": {
-    "url": "https://github.com/kevva/shebang-command/issues"
-  },
-  "bundleDependencies": false,
-  "dependencies": {
-    "shebang-regex": "^1.0.0"
-  },
-  "deprecated": false,
-  "description": "Get the command from a shebang",
-  "devDependencies": {
-    "ava": "*",
-    "xo": "*"
-  },
-  "engines": {
-    "node": ">=0.10.0"
-  },
-  "files": [
-    "index.js"
-  ],
-  "homepage": "https://github.com/kevva/shebang-command#readme",
-  "keywords": [
-    "cmd",
-    "command",
-    "parse",
-    "shebang"
-  ],
-  "license": "MIT",
-  "name": "shebang-command",
-  "repository": {
-    "type": "git",
-    "url": "git+https://github.com/kevva/shebang-command.git"
-  },
-  "scripts": {
-    "test": "xo && ava"
-  },
-  "version": "1.2.0",
-  "xo": {
-    "ignores": [
-      "test.js"
-    ]
-  }
-}

+ 0 - 39
node_modules.bak/shebang-command/readme.md

@@ -1,39 +0,0 @@
-# shebang-command [![Build Status](https://travis-ci.org/kevva/shebang-command.svg?branch=master)](https://travis-ci.org/kevva/shebang-command)
-
-> Get the command from a shebang
-
-
-## Install
-
-```
-$ npm install --save shebang-command
-```
-
-
-## Usage
-
-```js
-const shebangCommand = require('shebang-command');
-
-shebangCommand('#!/usr/bin/env node');
-//=> 'node'
-
-shebangCommand('#!/bin/bash');
-//=> 'bash'
-```
-
-
-## API
-
-### shebangCommand(string)
-
-#### string
-
-Type: `string`
-
-String containing a shebang.
-
-
-## License
-
-MIT © [Kevin Martensson](http://github.com/kevva)

+ 0 - 2
node_modules.bak/shebang-regex/index.js

@@ -1,2 +0,0 @@
-'use strict';
-module.exports = /^#!.*/;

+ 0 - 21
node_modules.bak/shebang-regex/license

@@ -1,21 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.

+ 0 - 64
node_modules.bak/shebang-regex/package.json

@@ -1,64 +0,0 @@
-{
-  "_from": "shebang-regex@^1.0.0",
-  "_id": "shebang-regex@1.0.0",
-  "_inBundle": false,
-  "_integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=",
-  "_location": "/shebang-regex",
-  "_phantomChildren": {},
-  "_requested": {
-    "type": "range",
-    "registry": true,
-    "raw": "shebang-regex@^1.0.0",
-    "name": "shebang-regex",
-    "escapedName": "shebang-regex",
-    "rawSpec": "^1.0.0",
-    "saveSpec": null,
-    "fetchSpec": "^1.0.0"
-  },
-  "_requiredBy": [
-    "/shebang-command"
-  ],
-  "_resolved": "https://registry.npm.taobao.org/shebang-regex/download/shebang-regex-1.0.0.tgz",
-  "_shasum": "da42f49740c0b42db2ca9728571cb190c98efea3",
-  "_spec": "shebang-regex@^1.0.0",
-  "_where": "D:\\朗通信息\\icssDService\\node_modules\\shebang-command",
-  "author": {
-    "name": "Sindre Sorhus",
-    "email": "sindresorhus@gmail.com",
-    "url": "sindresorhus.com"
-  },
-  "bugs": {
-    "url": "https://github.com/sindresorhus/shebang-regex/issues"
-  },
-  "bundleDependencies": false,
-  "deprecated": false,
-  "description": "Regular expression for matching a shebang",
-  "devDependencies": {
-    "ava": "0.0.4"
-  },
-  "engines": {
-    "node": ">=0.10.0"
-  },
-  "files": [
-    "index.js"
-  ],
-  "homepage": "https://github.com/sindresorhus/shebang-regex#readme",
-  "keywords": [
-    "re",
-    "regex",
-    "regexp",
-    "shebang",
-    "match",
-    "test"
-  ],
-  "license": "MIT",
-  "name": "shebang-regex",
-  "repository": {
-    "type": "git",
-    "url": "git+https://github.com/sindresorhus/shebang-regex.git"
-  },
-  "scripts": {
-    "test": "node test.js"
-  },
-  "version": "1.0.0"
-}

+ 0 - 29
node_modules.bak/shebang-regex/readme.md

@@ -1,29 +0,0 @@
-# shebang-regex [![Build Status](https://travis-ci.org/sindresorhus/shebang-regex.svg?branch=master)](https://travis-ci.org/sindresorhus/shebang-regex)
-
-> Regular expression for matching a [shebang](https://en.wikipedia.org/wiki/Shebang_(Unix))
-
-
-## Install
-
-```
-$ npm install --save shebang-regex
-```
-
-
-## Usage
-
-```js
-var shebangRegex = require('shebang-regex');
-var str = '#!/usr/bin/env node\nconsole.log("unicorns");';
-
-shebangRegex.test(str);
-//=> true
-
-shebangRegex.exec(str)[0];
-//=> '#!/usr/bin/env node'
-```
-
-
-## License
-
-MIT © [Sindre Sorhus](http://sindresorhus.com)

+ 0 - 35
node_modules.bak/signal-exit/CHANGELOG.md

@@ -1,35 +0,0 @@
-# Changelog
-
-All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
-
-### [3.0.3](https://github.com/tapjs/signal-exit/compare/v3.0.2...v3.0.3) (2020-03-26)
-
-
-### Bug Fixes
-
-* patch `SIGHUP` to `SIGINT` when on Windows ([cfd1046](https://github.com/tapjs/signal-exit/commit/cfd1046079af4f0e44f93c69c237a09de8c23ef2))
-* **ci:** use Travis for Windows builds ([007add7](https://github.com/tapjs/signal-exit/commit/007add793d2b5ae3c382512103adbf321768a0b8))
-
-<a name="3.0.1"></a>
-## [3.0.1](https://github.com/tapjs/signal-exit/compare/v3.0.0...v3.0.1) (2016-09-08)
-
-
-### Bug Fixes
-
-* do not listen on SIGBUS, SIGFPE, SIGSEGV and SIGILL ([#40](https://github.com/tapjs/signal-exit/issues/40)) ([5b105fb](https://github.com/tapjs/signal-exit/commit/5b105fb))
-
-
-
-<a name="3.0.0"></a>
-# [3.0.0](https://github.com/tapjs/signal-exit/compare/v2.1.2...v3.0.0) (2016-06-13)
-
-
-### Bug Fixes
-
-* get our test suite running on Windows ([#23](https://github.com/tapjs/signal-exit/issues/23)) ([6f3eda8](https://github.com/tapjs/signal-exit/commit/6f3eda8))
-* hooking SIGPROF was interfering with profilers see [#21](https://github.com/tapjs/signal-exit/issues/21) ([#24](https://github.com/tapjs/signal-exit/issues/24)) ([1248a4c](https://github.com/tapjs/signal-exit/commit/1248a4c))
-
-
-### BREAKING CHANGES
-
-* signal-exit no longer wires into SIGPROF

+ 0 - 16
node_modules.bak/signal-exit/LICENSE.txt

@@ -1,16 +0,0 @@
-The ISC License
-
-Copyright (c) 2015, Contributors
-
-Permission to use, copy, modify, and/or distribute this software
-for any purpose with or without fee is hereby granted, provided
-that the above copyright notice and this permission notice
-appear in all copies.
-
-THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
-WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
-OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE
-LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES
-OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
-WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
-ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

+ 0 - 39
node_modules.bak/signal-exit/README.md

@@ -1,39 +0,0 @@
-# signal-exit
-
-[![Build Status](https://travis-ci.org/tapjs/signal-exit.png)](https://travis-ci.org/tapjs/signal-exit)
-[![Coverage](https://coveralls.io/repos/tapjs/signal-exit/badge.svg?branch=master)](https://coveralls.io/r/tapjs/signal-exit?branch=master)
-[![NPM version](https://img.shields.io/npm/v/signal-exit.svg)](https://www.npmjs.com/package/signal-exit)
-[![Standard Version](https://img.shields.io/badge/release-standard%20version-brightgreen.svg)](https://github.com/conventional-changelog/standard-version)
-
-When you want to fire an event no matter how a process exits:
-
-* reaching the end of execution.
-* explicitly having `process.exit(code)` called.
-* having `process.kill(pid, sig)` called.
-* receiving a fatal signal from outside the process
-
-Use `signal-exit`.
-
-```js
-var onExit = require('signal-exit')
-
-onExit(function (code, signal) {
-  console.log('process exited!')
-})
-```
-
-## API
-
-`var remove = onExit(function (code, signal) {}, options)`
-
-The return value of the function is a function that will remove the
-handler.
-
-Note that the function *only* fires for signals if the signal would
-cause the proces to exit.  That is, there are no other listeners, and
-it is a fatal signal.
-
-## Options
-
-* `alwaysLast`: Run this handler after any other signal or exit
-  handlers.  This causes `process.emit` to be monkeypatched.

+ 0 - 163
node_modules.bak/signal-exit/index.js

@@ -1,163 +0,0 @@
-// Note: since nyc uses this module to output coverage, any lines
-// that are in the direct sync flow of nyc's outputCoverage are
-// ignored, since we can never get coverage for them.
-var assert = require('assert')
-var signals = require('./signals.js')
-var isWin = /^win/i.test(process.platform)
-
-var EE = require('events')
-/* istanbul ignore if */
-if (typeof EE !== 'function') {
-  EE = EE.EventEmitter
-}
-
-var emitter
-if (process.__signal_exit_emitter__) {
-  emitter = process.__signal_exit_emitter__
-} else {
-  emitter = process.__signal_exit_emitter__ = new EE()
-  emitter.count = 0
-  emitter.emitted = {}
-}
-
-// Because this emitter is a global, we have to check to see if a
-// previous version of this library failed to enable infinite listeners.
-// I know what you're about to say.  But literally everything about
-// signal-exit is a compromise with evil.  Get used to it.
-if (!emitter.infinite) {
-  emitter.setMaxListeners(Infinity)
-  emitter.infinite = true
-}
-
-module.exports = function (cb, opts) {
-  assert.equal(typeof cb, 'function', 'a callback must be provided for exit handler')
-
-  if (loaded === false) {
-    load()
-  }
-
-  var ev = 'exit'
-  if (opts && opts.alwaysLast) {
-    ev = 'afterexit'
-  }
-
-  var remove = function () {
-    emitter.removeListener(ev, cb)
-    if (emitter.listeners('exit').length === 0 &&
-        emitter.listeners('afterexit').length === 0) {
-      unload()
-    }
-  }
-  emitter.on(ev, cb)
-
-  return remove
-}
-
-module.exports.unload = unload
-function unload () {
-  if (!loaded) {
-    return
-  }
-  loaded = false
-
-  signals.forEach(function (sig) {
-    try {
-      process.removeListener(sig, sigListeners[sig])
-    } catch (er) {}
-  })
-  process.emit = originalProcessEmit
-  process.reallyExit = originalProcessReallyExit
-  emitter.count -= 1
-}
-
-function emit (event, code, signal) {
-  if (emitter.emitted[event]) {
-    return
-  }
-  emitter.emitted[event] = true
-  emitter.emit(event, code, signal)
-}
-
-// { <signal>: <listener fn>, ... }
-var sigListeners = {}
-signals.forEach(function (sig) {
-  sigListeners[sig] = function listener () {
-    // If there are no other listeners, an exit is coming!
-    // Simplest way: remove us and then re-send the signal.
-    // We know that this will kill the process, so we can
-    // safely emit now.
-    var listeners = process.listeners(sig)
-    if (listeners.length === emitter.count) {
-      unload()
-      emit('exit', null, sig)
-      /* istanbul ignore next */
-      emit('afterexit', null, sig)
-      /* istanbul ignore next */
-      if (isWin && sig === 'SIGHUP') {
-        // "SIGHUP" throws an `ENOSYS` error on Windows,
-        // so use a supported signal instead
-        sig = 'SIGINT'
-      }
-      process.kill(process.pid, sig)
-    }
-  }
-})
-
-module.exports.signals = function () {
-  return signals
-}
-
-module.exports.load = load
-
-var loaded = false
-
-function load () {
-  if (loaded) {
-    return
-  }
-  loaded = true
-
-  // This is the number of onSignalExit's that are in play.
-  // It's important so that we can count the correct number of
-  // listeners on signals, and don't wait for the other one to
-  // handle it instead of us.
-  emitter.count += 1
-
-  signals = signals.filter(function (sig) {
-    try {
-      process.on(sig, sigListeners[sig])
-      return true
-    } catch (er) {
-      return false
-    }
-  })
-
-  process.emit = processEmit
-  process.reallyExit = processReallyExit
-}
-
-var originalProcessReallyExit = process.reallyExit
-function processReallyExit (code) {
-  process.exitCode = code || 0
-  emit('exit', process.exitCode, null)
-  /* istanbul ignore next */
-  emit('afterexit', process.exitCode, null)
-  /* istanbul ignore next */
-  originalProcessReallyExit.call(process, process.exitCode)
-}
-
-var originalProcessEmit = process.emit
-function processEmit (ev, arg) {
-  if (ev === 'exit') {
-    if (arg !== undefined) {
-      process.exitCode = arg
-    }
-    var ret = originalProcessEmit.apply(this, arguments)
-    emit('exit', process.exitCode, null)
-    /* istanbul ignore next */
-    emit('afterexit', process.exitCode, null)
-    return ret
-  } else {
-    return originalProcessEmit.apply(this, arguments)
-  }
-}

+ 0 - 66
node_modules.bak/signal-exit/package.json

@@ -1,66 +0,0 @@
-{
-  "_from": "signal-exit@^3.0.0",
-  "_id": "signal-exit@3.0.3",
-  "_inBundle": false,
-  "_integrity": "sha1-oUEMLt2PB3sItOJTyOrPyvBXRhw=",
-  "_location": "/signal-exit",
-  "_phantomChildren": {},
-  "_requested": {
-    "type": "range",
-    "registry": true,
-    "raw": "signal-exit@^3.0.0",
-    "name": "signal-exit",
-    "escapedName": "signal-exit",
-    "rawSpec": "^3.0.0",
-    "saveSpec": null,
-    "fetchSpec": "^3.0.0"
-  },
-  "_requiredBy": [
-    "/execa"
-  ],
-  "_resolved": "https://registry.npm.taobao.org/signal-exit/download/signal-exit-3.0.3.tgz",
-  "_shasum": "a1410c2edd8f077b08b4e253c8eacfcaf057461c",
-  "_spec": "signal-exit@^3.0.0",
-  "_where": "D:\\朗通信息\\icssDService\\node_modules\\execa",
-  "author": {
-    "name": "Ben Coe",
-    "email": "ben@npmjs.com"
-  },
-  "bugs": {
-    "url": "https://github.com/tapjs/signal-exit/issues"
-  },
-  "bundleDependencies": false,
-  "deprecated": false,
-  "description": "when you want to fire an event no matter how a process exits.",
-  "devDependencies": {
-    "chai": "^3.5.0",
-    "coveralls": "^2.11.10",
-    "nyc": "^8.1.0",
-    "standard": "^8.1.0",
-    "standard-version": "^2.3.0",
-    "tap": "^8.0.1"
-  },
-  "files": [
-    "index.js",
-    "signals.js"
-  ],
-  "homepage": "https://github.com/tapjs/signal-exit",
-  "keywords": [
-    "signal",
-    "exit"
-  ],
-  "license": "ISC",
-  "main": "index.js",
-  "name": "signal-exit",
-  "repository": {
-    "type": "git",
-    "url": "git+https://github.com/tapjs/signal-exit.git"
-  },
-  "scripts": {
-    "coverage": "nyc report --reporter=text-lcov | coveralls",
-    "pretest": "standard",
-    "release": "standard-version",
-    "test": "tap --timeout=240 ./test/*.js --cov"
-  },
-  "version": "3.0.3"
-}

+ 0 - 53
node_modules.bak/signal-exit/signals.js

@@ -1,53 +0,0 @@
-// This is not the set of all possible signals.
-//
-// It IS, however, the set of all signals that trigger
-// an exit on either Linux or BSD systems.  Linux is a
-// superset of the signal names supported on BSD, and
-// the unknown signals just fail to register, so we can
-// catch that easily enough.
-//
-// Don't bother with SIGKILL.  It's uncatchable, which
-// means that we can't fire any callbacks anyway.
-//
-// If a user does happen to register a handler on a non-
-// fatal signal like SIGWINCH or something, and then
-// exit, it'll end up firing `process.emit('exit')`, so
-// the handler will be fired anyway.
-//
-// SIGBUS, SIGFPE, SIGSEGV and SIGILL, when not raised
-// artificially, inherently leave the process in a
-// state from which it is not safe to try and enter JS
-// listeners.
-module.exports = [
-  'SIGABRT',
-  'SIGALRM',
-  'SIGHUP',
-  'SIGINT',
-  'SIGTERM'
-]
-
-if (process.platform !== 'win32') {
-  module.exports.push(
-    'SIGVTALRM',
-    'SIGXCPU',
-    'SIGXFSZ',
-    'SIGUSR2',
-    'SIGTRAP',
-    'SIGSYS',
-    'SIGQUIT',
-    'SIGIOT'
-    // should detect profiler and enable/disable accordingly.
-    // see #21
-    // 'SIGPROF'
-  )
-}
-
-if (process.platform === 'linux') {
-  module.exports.push(
-    'SIGIO',
-    'SIGPOLL',
-    'SIGPWR',
-    'SIGSTKFLT',
-    'SIGUNUSED'
-  )
-}

+ 0 - 21
node_modules.bak/snapdragon-node/LICENSE

@@ -1,21 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) 2017, Jon Schlinkert
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.

文件差异内容过多而无法显示
+ 0 - 453
node_modules.bak/snapdragon-node/README.md


+ 0 - 492
node_modules.bak/snapdragon-node/index.js

@@ -1,492 +0,0 @@
-'use strict';
-
-var isObject = require('isobject');
-var define = require('define-property');
-var utils = require('snapdragon-util');
-var ownNames;
-
-/**
- * Create a new AST `Node` with the given `val` and `type`.
- *
- * ```js
- * var node = new Node('*', 'Star');
- * var node = new Node({type: 'star', val: '*'});
- * ```
- * @name Node
- * @param {String|Object} `val` Pass a matched substring, or an object to merge onto the node.
- * @param {String} `type` The node type to use when `val` is a string.
- * @return {Object} node instance
- * @api public
- */
-
-function Node(val, type, parent) {
-  if (typeof type !== 'string') {
-    parent = type;
-    type = null;
-  }
-
-  define(this, 'parent', parent);
-  define(this, 'isNode', true);
-  define(this, 'expect', null);
-
-  if (typeof type !== 'string' && isObject(val)) {
-    lazyKeys();
-    var keys = Object.keys(val);
-    for (var i = 0; i < keys.length; i++) {
-      var key = keys[i];
-      if (ownNames.indexOf(key) === -1) {
-        this[key] = val[key];
-      }
-    }
-  } else {
-    this.type = type;
-    this.val = val;
-  }
-}
-
-/**
- * Returns true if the given value is a node.
- *
- * ```js
- * var Node = require('snapdragon-node');
- * var node = new Node({type: 'foo'});
- * console.log(Node.isNode(node)); //=> true
- * console.log(Node.isNode({})); //=> false
- * ```
- * @param {Object} `node`
- * @returns {Boolean}
- * @api public
- */
-
-Node.isNode = function(node) {
-  return utils.isNode(node);
-};
-
-/**
- * Define a non-enumberable property on the node instance.
- * Useful for adding properties that shouldn't be extended
- * or visible during debugging.
- *
- * ```js
- * var node = new Node();
- * node.define('foo', 'something non-enumerable');
- * ```
- * @param {String} `name`
- * @param {any} `val`
- * @return {Object} returns the node instance
- * @api public
- */
-
-Node.prototype.define = function(name, val) {
-  define(this, name, val);
-  return this;
-};
-
-/**
- * Returns true if `node.val` is an empty string, or `node.nodes` does
- * not contain any non-empty text nodes.
- *
- * ```js
- * var node = new Node({type: 'text'});
- * node.isEmpty(); //=> true
- * node.val = 'foo';
- * node.isEmpty(); //=> false
- * ```
- * @param {Function} `fn` (optional) Filter function that is called on `node` and/or child nodes. `isEmpty` will return false immediately when the filter function returns false on any nodes.
- * @return {Boolean}
- * @api public
- */
-
-Node.prototype.isEmpty = function(fn) {
-  return utils.isEmpty(this, fn);
-};
-
-/**
- * Given node `foo` and node `bar`, push node `bar` onto `foo.nodes`, and
- * set `foo` as `bar.parent`.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * foo.push(bar);
- * ```
- * @param {Object} `node`
- * @return {Number} Returns the length of `node.nodes`
- * @api public
- */
-
-Node.prototype.push = function(node) {
-  assert(Node.isNode(node), 'expected node to be an instance of Node');
-  define(node, 'parent', this);
-
-  this.nodes = this.nodes || [];
-  return this.nodes.push(node);
-};
-
-/**
- * Given node `foo` and node `bar`, unshift node `bar` onto `foo.nodes`, and
- * set `foo` as `bar.parent`.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * foo.unshift(bar);
- * ```
- * @param {Object} `node`
- * @return {Number} Returns the length of `node.nodes`
- * @api public
- */
-
-Node.prototype.unshift = function(node) {
-  assert(Node.isNode(node), 'expected node to be an instance of Node');
-  define(node, 'parent', this);
-
-  this.nodes = this.nodes || [];
-  return this.nodes.unshift(node);
-};
-
-/**
- * Pop a node from `node.nodes`.
- *
- * ```js
- * var node = new Node({type: 'foo'});
- * node.push(new Node({type: 'a'}));
- * node.push(new Node({type: 'b'}));
- * node.push(new Node({type: 'c'}));
- * node.push(new Node({type: 'd'}));
- * console.log(node.nodes.length);
- * //=> 4
- * node.pop();
- * console.log(node.nodes.length);
- * //=> 3
- * ```
- * @return {Number} Returns the popped `node`
- * @api public
- */
-
-Node.prototype.pop = function() {
-  return this.nodes && this.nodes.pop();
-};
-
-/**
- * Shift a node from `node.nodes`.
- *
- * ```js
- * var node = new Node({type: 'foo'});
- * node.push(new Node({type: 'a'}));
- * node.push(new Node({type: 'b'}));
- * node.push(new Node({type: 'c'}));
- * node.push(new Node({type: 'd'}));
- * console.log(node.nodes.length);
- * //=> 4
- * node.shift();
- * console.log(node.nodes.length);
- * //=> 3
- * ```
- * @return {Object} Returns the shifted `node`
- * @api public
- */
-
-Node.prototype.shift = function() {
-  return this.nodes && this.nodes.shift();
-};
-
-/**
- * Remove `node` from `node.nodes`.
- *
- * ```js
- * node.remove(childNode);
- * ```
- * @param {Object} `node`
- * @return {Object} Returns the removed node.
- * @api public
- */
-
-Node.prototype.remove = function(node) {
-  assert(Node.isNode(node), 'expected node to be an instance of Node');
-  this.nodes = this.nodes || [];
-  var idx = node.index;
-  if (idx !== -1) {
-    node.index = -1;
-    return this.nodes.splice(idx, 1);
-  }
-  return null;
-};
-
-/**
- * Get the first child node from `node.nodes` that matches the given `type`.
- * If `type` is a number, the child node at that index is returned.
- *
- * ```js
- * var child = node.find(1); //<= index of the node to get
- * var child = node.find('foo'); //<= node.type of a child node
- * var child = node.find(/^(foo|bar)$/); //<= regex to match node.type
- * var child = node.find(['foo', 'bar']); //<= array of node.type(s)
- * ```
- * @param {String} `type`
- * @return {Object} Returns a child node or undefined.
- * @api public
- */
-
-Node.prototype.find = function(type) {
-  return utils.findNode(this.nodes, type);
-};
-
-/**
- * Return true if the node is the given `type`.
- *
- * ```js
- * var node = new Node({type: 'bar'});
- * cosole.log(node.isType('foo'));          // false
- * cosole.log(node.isType(/^(foo|bar)$/));  // true
- * cosole.log(node.isType(['foo', 'bar'])); // true
- * ```
- * @param {String} `type`
- * @return {Boolean}
- * @api public
- */
-
-Node.prototype.isType = function(type) {
-  return utils.isType(this, type);
-};
-
-/**
- * Return true if the `node.nodes` has the given `type`.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * foo.push(bar);
- *
- * cosole.log(foo.hasType('qux'));          // false
- * cosole.log(foo.hasType(/^(qux|bar)$/));  // true
- * cosole.log(foo.hasType(['qux', 'bar'])); // true
- * ```
- * @param {String} `type`
- * @return {Boolean}
- * @api public
- */
-
-Node.prototype.hasType = function(type) {
-  return utils.hasType(this, type);
-};
-
-/**
- * Get the siblings array, or `null` if it doesn't exist.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * var baz = new Node({type: 'baz'});
- * foo.push(bar);
- * foo.push(baz);
- *
- * console.log(bar.siblings.length) // 2
- * console.log(baz.siblings.length) // 2
- * ```
- * @return {Array}
- * @api public
- */
-
-Object.defineProperty(Node.prototype, 'siblings', {
-  set: function() {
-    throw new Error('node.siblings is a getter and cannot be defined');
-  },
-  get: function() {
-    return this.parent ? this.parent.nodes : null;
-  }
-});
-
-/**
- * Get the node's current index from `node.parent.nodes`.
- * This should always be correct, even when the parent adds nodes.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * var baz = new Node({type: 'baz'});
- * var qux = new Node({type: 'qux'});
- * foo.push(bar);
- * foo.push(baz);
- * foo.unshift(qux);
- *
- * console.log(bar.index) // 1
- * console.log(baz.index) // 2
- * console.log(qux.index) // 0
- * ```
- * @return {Number}
- * @api public
- */
-
-Object.defineProperty(Node.prototype, 'index', {
-  set: function(index) {
-    define(this, 'idx', index);
-  },
-  get: function() {
-    if (!Array.isArray(this.siblings)) {
-      return -1;
-    }
-    var tok = this.idx !== -1 ? this.siblings[this.idx] : null;
-    if (tok !== this) {
-      this.idx = this.siblings.indexOf(this);
-    }
-    return this.idx;
-  }
-});
-
-/**
- * Get the previous node from the siblings array or `null`.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * var baz = new Node({type: 'baz'});
- * foo.push(bar);
- * foo.push(baz);
- *
- * console.log(baz.prev.type) // 'bar'
- * ```
- * @return {Object}
- * @api public
- */
-
-Object.defineProperty(Node.prototype, 'prev', {
-  set: function() {
-    throw new Error('node.prev is a getter and cannot be defined');
-  },
-  get: function() {
-    if (Array.isArray(this.siblings)) {
-      return this.siblings[this.index - 1] || this.parent.prev;
-    }
-    return null;
-  }
-});
-
-/**
- * Get the siblings array, or `null` if it doesn't exist.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * var baz = new Node({type: 'baz'});
- * foo.push(bar);
- * foo.push(baz);
- *
- * console.log(bar.siblings.length) // 2
- * console.log(baz.siblings.length) // 2
- * ```
- * @return {Object}
- * @api public
- */
-
-Object.defineProperty(Node.prototype, 'next', {
-  set: function() {
-    throw new Error('node.next is a getter and cannot be defined');
-  },
-  get: function() {
-    if (Array.isArray(this.siblings)) {
-      return this.siblings[this.index + 1] || this.parent.next;
-    }
-    return null;
-  }
-});
-
-/**
- * Get the first node from `node.nodes`.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * var baz = new Node({type: 'baz'});
- * var qux = new Node({type: 'qux'});
- * foo.push(bar);
- * foo.push(baz);
- * foo.push(qux);
- *
- * console.log(foo.first.type) // 'bar'
- * ```
- * @return {Object} The first node, or undefiend
- * @api public
- */
-
-Object.defineProperty(Node.prototype, 'first', {
-  get: function() {
-    return this.nodes ? this.nodes[0] : null;
-  }
-});
-
-/**
- * Get the last node from `node.nodes`.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * var baz = new Node({type: 'baz'});
- * var qux = new Node({type: 'qux'});
- * foo.push(bar);
- * foo.push(baz);
- * foo.push(qux);
- *
- * console.log(foo.last.type) // 'qux'
- * ```
- * @return {Object} The last node, or undefiend
- * @api public
- */
-
-Object.defineProperty(Node.prototype, 'last', {
-  get: function() {
-    return this.nodes ? utils.last(this.nodes) : null;
-  }
-});
-
-/**
- * Get the last node from `node.nodes`.
- *
- * ```js
- * var foo = new Node({type: 'foo'});
- * var bar = new Node({type: 'bar'});
- * var baz = new Node({type: 'baz'});
- * var qux = new Node({type: 'qux'});
- * foo.push(bar);
- * foo.push(baz);
- * foo.push(qux);
- *
- * console.log(foo.last.type) // 'qux'
- * ```
- * @return {Object} The last node, or undefiend
- * @api public
- */
-
-Object.defineProperty(Node.prototype, 'scope', {
-  get: function() {
-    if (this.isScope !== true) {
-      return this.parent ? this.parent.scope : this;
-    }
-    return this;
-  }
-});
-
-/**
- * Get own property names from Node prototype, but only the
- * first time `Node` is instantiated
- */
-
-function lazyKeys() {
-  if (!ownNames) {
-    ownNames = Object.getOwnPropertyNames(Node.prototype);
-  }
-}
-
-/**
- * Simplified assertion. Throws an error is `val` is falsey.
- */
-
-function assert(val, message) {
-  if (!val) throw new Error(message);
-}
-
-/**
- * Expose `Node`
- */
-
-exports = module.exports = Node;

+ 0 - 109
node_modules.bak/snapdragon-node/package.json

@@ -1,109 +0,0 @@
-{
-  "_from": "snapdragon-node@^2.0.1",
-  "_id": "snapdragon-node@2.1.1",
-  "_inBundle": false,
-  "_integrity": "sha1-bBdfhv8UvbByRWPo88GwIaKGhTs=",
-  "_location": "/snapdragon-node",
-  "_phantomChildren": {
-    "kind-of": "6.0.3"
-  },
-  "_requested": {
-    "type": "range",
-    "registry": true,
-    "raw": "snapdragon-node@^2.0.1",
-    "name": "snapdragon-node",
-    "escapedName": "snapdragon-node",
-    "rawSpec": "^2.0.1",
-    "saveSpec": null,
-    "fetchSpec": "^2.0.1"
-  },
-  "_requiredBy": [
-    "/braces"
-  ],
-  "_resolved": "https://registry.npm.taobao.org/snapdragon-node/download/snapdragon-node-2.1.1.tgz",
-  "_shasum": "6c175f86ff14bdb0724563e8f3c1b021a286853b",
-  "_spec": "snapdragon-node@^2.0.1",
-  "_where": "D:\\朗通信息\\icssDService\\node_modules\\braces",
-  "author": {
-    "name": "Jon Schlinkert",
-    "url": "https://github.com/jonschlinkert"
-  },
-  "bugs": {
-    "url": "https://github.com/jonschlinkert/snapdragon-node/issues"
-  },
-  "bundleDependencies": false,
-  "dependencies": {
-    "define-property": "^1.0.0",
-    "isobject": "^3.0.0",
-    "snapdragon-util": "^3.0.1"
-  },
-  "deprecated": false,
-  "description": "Snapdragon utility for creating a new AST node in custom code, such as plugins.",
-  "devDependencies": {
-    "gulp": "^3.9.1",
-    "gulp-eslint": "^4.0.0",
-    "gulp-format-md": "^0.1.12",
-    "gulp-istanbul": "^1.1.2",
-    "gulp-mocha": "^3.0.1",
-    "mocha": "^3.4.2",
-    "snapdragon": "^0.11.0"
-  },
-  "engines": {
-    "node": ">=0.10.0"
-  },
-  "files": [
-    "index.js"
-  ],
-  "homepage": "https://github.com/jonschlinkert/snapdragon-node",
-  "keywords": [
-    "ast",
-    "compile",
-    "compiler",
-    "convert",
-    "node",
-    "parse",
-    "parser",
-    "plugin",
-    "render",
-    "snapdragon",
-    "snapdragonplugin",
-    "token",
-    "transform"
-  ],
-  "license": "MIT",
-  "main": "index.js",
-  "name": "snapdragon-node",
-  "repository": {
-    "type": "git",
-    "url": "git+https://github.com/jonschlinkert/snapdragon-node.git"
-  },
-  "scripts": {
-    "test": "mocha"
-  },
-  "verb": {
-    "layout": "default",
-    "tasks": [
-      "readme"
-    ],
-    "plugins": [
-      "gulp-format-md"
-    ],
-    "related": {
-      "list": [
-        "breakdance",
-        "snapdragon",
-        "snapdragon-capture",
-        "snapdragon-cheerio",
-        "snapdragon-util"
-      ]
-    },
-    "reflinks": [
-      "verb",
-      "verb-generate-readme"
-    ],
-    "lint": {
-      "reflinks": true
-    }
-  },
-  "version": "2.1.1"
-}

+ 0 - 21
node_modules.bak/snapdragon-util/LICENSE

@@ -1,21 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) 2017, Jon Schlinkert
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.

文件差异内容过多而无法显示
+ 0 - 807
node_modules.bak/snapdragon-util/README.md


文件差异内容过多而无法显示
+ 0 - 1019
node_modules.bak/snapdragon-util/index.js


+ 0 - 98
node_modules.bak/snapdragon-util/package.json

@@ -1,98 +0,0 @@
-{
-  "_from": "snapdragon-util@^3.0.1",
-  "_id": "snapdragon-util@3.0.1",
-  "_inBundle": false,
-  "_integrity": "sha1-+VZHlIbyrNeXAGk/b3uAXkWrVuI=",
-  "_location": "/snapdragon-util",
-  "_phantomChildren": {
-    "is-buffer": "1.1.6"
-  },
-  "_requested": {
-    "type": "range",
-    "registry": true,
-    "raw": "snapdragon-util@^3.0.1",
-    "name": "snapdragon-util",
-    "escapedName": "snapdragon-util",
-    "rawSpec": "^3.0.1",
-    "saveSpec": null,
-    "fetchSpec": "^3.0.1"
-  },
-  "_requiredBy": [
-    "/snapdragon-node"
-  ],
-  "_resolved": "https://registry.npm.taobao.org/snapdragon-util/download/snapdragon-util-3.0.1.tgz",
-  "_shasum": "f956479486f2acd79700693f6f7b805e45ab56e2",
-  "_spec": "snapdragon-util@^3.0.1",
-  "_where": "D:\\朗通信息\\icssDService\\node_modules\\snapdragon-node",
-  "author": {
-    "name": "Jon Schlinkert",
-    "url": "https://github.com/jonschlinkert"
-  },
-  "bugs": {
-    "url": "https://github.com/jonschlinkert/snapdragon-util/issues"
-  },
-  "bundleDependencies": false,
-  "dependencies": {
-    "kind-of": "^3.2.0"
-  },
-  "deprecated": false,
-  "description": "Utilities for the snapdragon parser/compiler.",
-  "devDependencies": {
-    "define-property": "^1.0.0",
-    "gulp": "^3.9.1",
-    "gulp-eslint": "^3.0.1",
-    "gulp-format-md": "^0.1.12",
-    "gulp-istanbul": "^1.1.1",
-    "gulp-mocha": "^3.0.0",
-    "isobject": "^3.0.0",
-    "mocha": "^3.3.0",
-    "snapdragon": "^0.11.0",
-    "snapdragon-node": "^1.0.6"
-  },
-  "engines": {
-    "node": ">=0.10.0"
-  },
-  "files": [
-    "index.js"
-  ],
-  "homepage": "https://github.com/jonschlinkert/snapdragon-util",
-  "keywords": [
-    "capture",
-    "compile",
-    "compiler",
-    "convert",
-    "match",
-    "parse",
-    "parser",
-    "plugin",
-    "render",
-    "snapdragon",
-    "snapdragonplugin",
-    "transform",
-    "util"
-  ],
-  "license": "MIT",
-  "main": "index.js",
-  "name": "snapdragon-util",
-  "repository": {
-    "type": "git",
-    "url": "git+https://github.com/jonschlinkert/snapdragon-util.git"
-  },
-  "scripts": {
-    "test": "mocha"
-  },
-  "verb": {
-    "toc": "collapsible",
-    "layout": "default",
-    "tasks": [
-      "readme"
-    ],
-    "plugins": [
-      "gulp-format-md"
-    ],
-    "lint": {
-      "reflinks": true
-    }
-  },
-  "version": "3.0.1"
-}

+ 0 - 21
node_modules.bak/snapdragon/LICENSE

@@ -1,21 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) 2015-2016, Jon Schlinkert.
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.

+ 0 - 321
node_modules.bak/snapdragon/README.md

@@ -1,321 +0,0 @@
-# snapdragon [![NPM version](https://img.shields.io/npm/v/snapdragon.svg?style=flat)](https://www.npmjs.com/package/snapdragon) [![NPM downloads](https://img.shields.io/npm/dm/snapdragon.svg?style=flat)](https://npmjs.org/package/snapdragon) [![Build Status](https://img.shields.io/travis/jonschlinkert/snapdragon.svg?style=flat)](https://travis-ci.org/jonschlinkert/snapdragon)
-
-> Fast, pluggable and easy-to-use parser-renderer factory.
-
-## Install
-
-Install with [npm](https://www.npmjs.com/):
-
-```sh
-$ npm install --save snapdragon
-```
-
-Created by [jonschlinkert](https://github.com/jonschlinkert) and [doowb](https://github.com/doowb).
-
-**Features**
-
-* Bootstrap your own parser, get sourcemap support for free
-* All parsing and compiling is handled by simple, reusable middleware functions
-* Inspired by the parsers in [pug](http://jade-lang.com) and [css](https://github.com/reworkcss/css).
-
-## History
-
-### v0.5.0
-
-**Breaking changes**
-
-Substantial breaking changes were made in v0.5.0! Most of these changes are part of a larger refactor that will be finished in 0.6.0, including the introduction of a `Lexer` class.
-
-* Renderer was renamed to `Compiler`
-* the `.render` method was renamed to `.compile`
-* Many other smaller changes. A more detailed overview will be provided in 0.6.0. If you don't have to time review code, I recommend you wait for the 0.6.0 release.
-
-## Usage examples
-
-```js
-var Snapdragon = require('snapdragon');
-var snapdragon = new Snapdragon();
-```
-
-**Parse**
-
-```js
-var ast = snapdragon.parser('some string', options)
-  // parser middleware that can be called by other middleware
-  .set('foo', function () {})
-  // parser middleware, runs immediately in the order defined
-  .use(bar())
-  .use(baz())
-```
-
-**Render**
-
-```js
-// pass the `ast` from the parse method
-var res = snapdragon.compiler(ast)
-  // compiler middleware, called when the name of the middleware
-  // matches the `node.type` (defined in a parser middleware)
-  .set('bar', function () {})
-  .set('baz', function () {})
-  .compile()
-```
-
-See the [examples](./examples/).
-
-## Getting started
-
-**Parsers**
-
-Parsers are middleware functions used for parsing a string into an ast node.
-
-```js
-var ast = snapdragon.parser(str, options)
-  .use(function() {
-    var pos = this.position();
-    var m = this.match(/^\./);
-    if (!m) return;
-    return pos({
-      // `type` specifies the compiler to use
-      type: 'dot',
-      val: m[0]
-    });
-  })
-```
-
-**AST node**
-
-When the parser finds a match, `pos()` is called, pushing a token for that node onto the ast that looks something like:
-
-```js
-{ type: 'dot',
-  val: '.',
-  position:
-   { start: { lineno: 1, column: 1 },
-     end: { lineno: 1, column: 2 } }}
-```
-
-**Renderers**
-
-Renderers are _named_ middleware functions that visit over an array of ast nodes to compile a string.
-
-```js
-var res = snapdragon.compiler(ast)
-  .set('dot', function (node) {
-    console.log(node.val)
-    //=> '.'
-    return this.emit(node.val);
-  })
-```
-
-**Source maps**
-
-If you want source map support, make sure to emit the position as well.
-
-```js
-var res = snapdragon.compiler(ast)
-  .set('dot', function (node) {
-    return this.emit(node.val, node.position);
-  })
-```
-
-## Docs
-
-### Parser middleware
-
-A parser middleware is a function that returns an abject called a `token`. This token is pushed onto the AST as a node.
-
-**Example token**
-
-```js
-{ type: 'dot',
-  val: '.',
-  position:
-   { start: { lineno: 1, column: 1 },
-     end: { lineno: 1, column: 2 } }}
-```
-
-**Example parser middleware**
-
-Match a single `.` in a string:
-
-1. Get the starting position by calling `this.position()`
-2. pass a regex for matching a single dot to the `.match` method
-3. if **no match** is found, return `undefined`
-4. if a **match** is found, `pos()` is called, which returns a token with:
-  - `type`: the name of the [compiler] to use
-  - `val`: The actual value captured by the regex. In this case, a `.`. Note that you can capture and return whatever will be needed by the corresponding [compiler].
-  - The ending position: automatically calculated by adding the length of the first capture group to the starting position.
-
-## Renderer middleware
-
-Renderers are run when the name of the compiler middleware matches the `type` defined on an ast `node` (which is defined in a parser).
-
-**Example**
-
-Exercise: Parse a dot, then compile it as an escaped dot.
-
-```js
-var ast = snapdragon.parser('.')
-  .use(function () {
-    var pos = this.position();
-    var m = this.match(/^\./);
-    if (!m) return;
-    return pos({
-      // define the `type` of compiler to use
-      type: 'dot',
-      val: m[0]
-    })
-  })
-
-var result = snapdragon.compiler(ast)
-  .set('dot', function (node) {
-    return this.emit('\\' + node.val);
-  })
-  .compile()
-
-console.log(result.output);
-//=> '\.'
-```
-
-## API
-
-### [Parser](lib/parser.js#L19)
-
-Create a new `Parser` with the given `input` and `options`.
-
-**Params**
-
-* `input` **{String}**
-* `options` **{Object}**
-
-### [.define](lib/parser.js#L103)
-
-Define a non-enumberable property on the `Parser` instance.
-
-**Example**
-
-```js
-parser.define('foo', 'bar');
-```
-
-**Params**
-
-* `key` **{String}**: propery name
-* `val` **{any}**: property value
-* `returns` **{Object}**: Returns the Parser instance for chaining.
-
-Set parser `name` with the given `fn`
-
-**Params**
-
-* `name` **{String}**
-* `fn` **{Function}**
-
-Get parser `name`
-
-**Params**
-
-* `name` **{String}**
-
-Push a `token` onto the `type` stack.
-
-**Params**
-
-* `type` **{String}**
-* `returns` **{Object}** `token`
-
-Pop a token off of the `type` stack
-
-**Params**
-
-* `type` **{String}**
-* `returns` **{Object}**: Returns a token
-
-Return true if inside a `stack` node. Types are `braces`, `parens` or `brackets`.
-
-**Params**
-
-* `type` **{String}**
-* `returns` **{Boolean}**
-
-**Example**
-
-```js
-parser.isType(node, 'brace');
-```
-
-**Params**
-
-* `node` **{Object}**
-* `type` **{String}**
-* `returns` **{Boolean}**
-
-### [.define](lib/compiler.js#L71)
-
-Define a non-enumberable property on the `Compiler` instance.
-
-**Example**
-
-```js
-compiler.define('foo', 'bar');
-```
-
-**Params**
-
-* `key` **{String}**: propery name
-* `val` **{any}**: property value
-* `returns` **{Object}**: Returns the Compiler instance for chaining.
-
-## About
-
-### Related projects
-
-* [braces](https://www.npmjs.com/package/braces): Fastest brace expansion for node.js, with the most complete support for the Bash 4.3 braces… [more](https://github.com/jonschlinkert/braces) | [homepage](https://github.com/jonschlinkert/braces "Fastest brace expansion for node.js, with the most complete support for the Bash 4.3 braces specification.")
-* [expand-brackets](https://www.npmjs.com/package/expand-brackets): Expand POSIX bracket expressions (character classes) in glob patterns. | [homepage](https://github.com/jonschlinkert/expand-brackets "Expand POSIX bracket expressions (character classes) in glob patterns.")
-* [extglob](https://www.npmjs.com/package/extglob): Convert extended globs to regex-compatible strings. Add (almost) the expressive power of regular expressions to… [more](https://github.com/jonschlinkert/extglob) | [homepage](https://github.com/jonschlinkert/extglob "Convert extended globs to regex-compatible strings. Add (almost) the expressive power of regular expressions to glob patterns.")
-* [micromatch](https://www.npmjs.com/package/micromatch): Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch. | [homepage](https://github.com/jonschlinkert/micromatch "Glob matching for javascript/node.js. A drop-in replacement and faster alternative to minimatch and multimatch.")
-
-### Contributing
-
-Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).
-
-### Contributors
-
-| **Commits** | **Contributor**<br/> | 
-| --- | --- |
-| 106 | [jonschlinkert](https://github.com/jonschlinkert) |
-| 2 | [doowb](https://github.com/doowb) |
-
-### Building docs
-
-_(This document was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme) (a [verb](https://github.com/verbose/verb) generator), please don't edit the readme directly. Any changes to the readme must be made in [.verb.md](.verb.md).)_
-
-To generate the readme and API documentation with [verb](https://github.com/verbose/verb):
-
-```sh
-$ npm install -g verb verb-generate-readme && verb
-```
-
-### Running tests
-
-Install dev dependencies:
-
-```sh
-$ npm install -d && npm test
-```
-
-### Author
-
-**Jon Schlinkert**
-
-* [github/jonschlinkert](https://github.com/jonschlinkert)
-* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
-
-### License
-
-Copyright © 2016, [Jon Schlinkert](https://github.com/jonschlinkert).
-Released under the [MIT license](https://github.com/jonschlinkert/snapdragon/blob/master/LICENSE).
-
-***
-
-_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.1.31, on October 10, 2016._

+ 0 - 174
node_modules.bak/snapdragon/index.js

@@ -1,174 +0,0 @@
-'use strict';
-
-var Base = require('base');
-var define = require('define-property');
-var Compiler = require('./lib/compiler');
-var Parser = require('./lib/parser');
-var utils = require('./lib/utils');
-var regexCache = {};
-var cache = {};
-
-/**
- * Create a new instance of `Snapdragon` with the given `options`.
- *
- * ```js
- * var snapdragon = new Snapdragon();
- * ```
- *
- * @param {Object} `options`
- * @api public
- */
-
-function Snapdragon(options) {
-  Base.call(this, null, options);
-  this.options = utils.extend({source: 'string'}, this.options);
-  this.compiler = new Compiler(this.options);
-  this.parser = new Parser(this.options);
-
-  Object.defineProperty(this, 'compilers', {
-    get: function() {
-      return this.compiler.compilers;
-    }
-  });
-
-  Object.defineProperty(this, 'parsers', {
-    get: function() {
-      return this.parser.parsers;
-    }
-  });
-
-  Object.defineProperty(this, 'regex', {
-    get: function() {
-      return this.parser.regex;
-    }
-  });
-}
-
-/**
- * Inherit Base
- */
-
-Base.extend(Snapdragon);
-
-/**
- * Add a parser to `snapdragon.parsers` for capturing the given `type` using
- * the specified regex or parser function. A function is useful if you need
- * to customize how the token is created and/or have access to the parser
- * instance to check options, etc.
- *
- * ```js
- * snapdragon
- *   .capture('slash', /^\//)
- *   .capture('dot', function() {
- *     var pos = this.position();
- *     var m = this.match(/^\./);
- *     if (!m) return;
- *     return pos({
- *       type: 'dot',
- *       val: m[0]
- *     });
- *   });
- * ```
- * @param {String} `type`
- * @param {RegExp|Function} `regex`
- * @return {Object} Returns the parser instance for chaining
- * @api public
- */
-
-Snapdragon.prototype.capture = function() {
-  return this.parser.capture.apply(this.parser, arguments);
-};
-
-/**
- * Register a plugin `fn`.
- *
- * ```js
- * var snapdragon = new Snapdgragon([options]);
- * snapdragon.use(function() {
- *   console.log(this);          //<= snapdragon instance
- *   console.log(this.parser);   //<= parser instance
- *   console.log(this.compiler); //<= compiler instance
- * });
- * ```
- * @param {Object} `fn`
- * @api public
- */
-
-Snapdragon.prototype.use = function(fn) {
-  fn.call(this, this);
-  return this;
-};
-
-/**
- * Parse the given `str`.
- *
- * ```js
- * var snapdragon = new Snapdgragon([options]);
- * // register parsers
- * snapdragon.parser.use(function() {});
- *
- * // parse
- * var ast = snapdragon.parse('foo/bar');
- * console.log(ast);
- * ```
- * @param {String} `str`
- * @param {Object} `options` Set `options.sourcemap` to true to enable source maps.
- * @return {Object} Returns an AST.
- * @api public
- */
-
-Snapdragon.prototype.parse = function(str, options) {
-  this.options = utils.extend({}, this.options, options);
-  var parsed = this.parser.parse(str, this.options);
-
-  // add non-enumerable parser reference
-  define(parsed, 'parser', this.parser);
-  return parsed;
-};
-
-/**
- * Compile the given `AST`.
- *
- * ```js
- * var snapdragon = new Snapdgragon([options]);
- * // register plugins
- * snapdragon.use(function() {});
- * // register parser plugins
- * snapdragon.parser.use(function() {});
- * // register compiler plugins
- * snapdragon.compiler.use(function() {});
- *
- * // parse
- * var ast = snapdragon.parse('foo/bar');
- *
- * // compile
- * var res = snapdragon.compile(ast);
- * console.log(res.output);
- * ```
- * @param {Object} `ast`
- * @param {Object} `options`
- * @return {Object} Returns an object with an `output` property with the rendered string.
- * @api public
- */
-
-Snapdragon.prototype.compile = function(ast, options) {
-  this.options = utils.extend({}, this.options, options);
-  var compiled = this.compiler.compile(ast, this.options);
-
-  // add non-enumerable compiler reference
-  define(compiled, 'compiler', this.compiler);
-  return compiled;
-};
-
-/**
- * Expose `Snapdragon`
- */
-
-module.exports = Snapdragon;
-
-/**
- * Expose `Parser` and `Compiler`
- */
-
-module.exports.Compiler = Compiler;
-module.exports.Parser = Parser;

+ 0 - 177
node_modules.bak/snapdragon/lib/compiler.js

@@ -1,177 +0,0 @@
-'use strict';
-
-var use = require('use');
-var define = require('define-property');
-var debug = require('debug')('snapdragon:compiler');
-var utils = require('./utils');
-
-/**
- * Create a new `Compiler` with the given `options`.
- * @param {Object} `options`
- */
-
-function Compiler(options, state) {
-  debug('initializing', __filename);
-  this.options = utils.extend({source: 'string'}, options);
-  this.state = state || {};
-  this.compilers = {};
-  this.output = '';
-  this.set('eos', function(node) {
-    return this.emit(node.val, node);
-  });
-  this.set('noop', function(node) {
-    return this.emit(node.val, node);
-  });
-  this.set('bos', function(node) {
-    return this.emit(node.val, node);
-  });
-  use(this);
-}
-
-/**
- * Prototype methods
- */
-
-Compiler.prototype = {
-
-  /**
-   * Throw an error message with details including the cursor position.
-   * @param {String} `msg` Message to use in the Error.
-   */
-
-  error: function(msg, node) {
-    var pos = node.position || {start: {column: 0}};
-    var message = this.options.source + ' column:' + pos.start.column + ': ' + msg;
-
-    var err = new Error(message);
-    err.reason = msg;
-    err.column = pos.start.column;
-    err.source = this.pattern;
-
-    if (this.options.silent) {
-      this.errors.push(err);
-    } else {
-      throw err;
-    }
-  },
-
-  /**
-   * Define a non-enumberable property on the `Compiler` instance.
-   *
-   * ```js
-   * compiler.define('foo', 'bar');
-   * ```
-   * @name .define
-   * @param {String} `key` propery name
-   * @param {any} `val` property value
-   * @return {Object} Returns the Compiler instance for chaining.
-   * @api public
-   */
-
-  define: function(key, val) {
-    define(this, key, val);
-    return this;
-  },
-
-  /**
-   * Emit `node.val`
-   */
-
-  emit: function(str, node) {
-    this.output += str;
-    return str;
-  },
-
-  /**
-   * Add a compiler `fn` with the given `name`
-   */
-
-  set: function(name, fn) {
-    this.compilers[name] = fn;
-    return this;
-  },
-
-  /**
-   * Get compiler `name`.
-   */
-
-  get: function(name) {
-    return this.compilers[name];
-  },
-
-  /**
-   * Get the previous AST node.
-   */
-
-  prev: function(n) {
-    return this.ast.nodes[this.idx - (n || 1)] || { type: 'bos', val: '' };
-  },
-
-  /**
-   * Get the next AST node.
-   */
-
-  next: function(n) {
-    return this.ast.nodes[this.idx + (n || 1)] || { type: 'eos', val: '' };
-  },
-
-  /**
-   * Visit `node`.
-   */
-
-  visit: function(node, nodes, i) {
-    var fn = this.compilers[node.type];
-    this.idx = i;
-
-    if (typeof fn !== 'function') {
-      throw this.error('compiler "' + node.type + '" is not registered', node);
-    }
-    return fn.call(this, node, nodes, i);
-  },
-
-  /**
-   * Map visit over array of `nodes`.
-   */
-
-  mapVisit: function(nodes) {
-    if (!Array.isArray(nodes)) {
-      throw new TypeError('expected an array');
-    }
-    var len = nodes.length;
-    var idx = -1;
-    while (++idx < len) {
-      this.visit(nodes[idx], nodes, idx);
-    }
-    return this;
-  },
-
-  /**
-   * Compile `ast`.
-   */
-
-  compile: function(ast, options) {
-    var opts = utils.extend({}, this.options, options);
-    this.ast = ast;
-    this.parsingErrors = this.ast.errors;
-    this.output = '';
-
-    // source map support
-    if (opts.sourcemap) {
-      var sourcemaps = require('./source-maps');
-      sourcemaps(this);
-      this.mapVisit(this.ast.nodes);
-      this.applySourceMaps();
-      this.map = opts.sourcemap === 'generator' ? this.map : this.map.toJSON();
-      return this;
-    }
-
-    this.mapVisit(this.ast.nodes);
-    return this;
-  }
-};
-
-/**
- * Expose `Compiler`
- */
-
-module.exports = Compiler;

+ 0 - 533
node_modules.bak/snapdragon/lib/parser.js

@@ -1,533 +0,0 @@
-'use strict';
-
-var use = require('use');
-var util = require('util');
-var Cache = require('map-cache');
-var define = require('define-property');
-var debug = require('debug')('snapdragon:parser');
-var Position = require('./position');
-var utils = require('./utils');
-
-/**
- * Create a new `Parser` with the given `input` and `options`.
- * @param {String} `input`
- * @param {Object} `options`
- * @api public
- */
-
-function Parser(options) {
-  debug('initializing', __filename);
-  this.options = utils.extend({source: 'string'}, options);
-  this.init(this.options);
-  use(this);
-}
-
-/**
- * Prototype methods
- */
-
-Parser.prototype = {
-  constructor: Parser,
-
-  init: function(options) {
-    this.orig = '';
-    this.input = '';
-    this.parsed = '';
-
-    this.column = 1;
-    this.line = 1;
-
-    this.regex = new Cache();
-    this.errors = this.errors || [];
-    this.parsers = this.parsers || {};
-    this.types = this.types || [];
-    this.sets = this.sets || {};
-    this.fns = this.fns || [];
-    this.currentType = 'root';
-
-    var pos = this.position();
-    this.bos = pos({type: 'bos', val: ''});
-
-    this.ast = {
-      type: 'root',
-      errors: this.errors,
-      nodes: [this.bos]
-    };
-
-    define(this.bos, 'parent', this.ast);
-    this.nodes = [this.ast];
-
-    this.count = 0;
-    this.setCount = 0;
-    this.stack = [];
-  },
-
-  /**
-   * Throw a formatted error with the cursor column and `msg`.
-   * @param {String} `msg` Message to use in the Error.
-   */
-
-  error: function(msg, node) {
-    var pos = node.position || {start: {column: 0, line: 0}};
-    var line = pos.start.line;
-    var column = pos.start.column;
-    var source = this.options.source;
-
-    var message = source + ' <line:' + line + ' column:' + column + '>: ' + msg;
-    var err = new Error(message);
-    err.source = source;
-    err.reason = msg;
-    err.pos = pos;
-
-    if (this.options.silent) {
-      this.errors.push(err);
-    } else {
-      throw err;
-    }
-  },
-
-  /**
-   * Define a non-enumberable property on the `Parser` instance.
-   *
-   * ```js
-   * parser.define('foo', 'bar');
-   * ```
-   * @name .define
-   * @param {String} `key` propery name
-   * @param {any} `val` property value
-   * @return {Object} Returns the Parser instance for chaining.
-   * @api public
-   */
-
-  define: function(key, val) {
-    define(this, key, val);
-    return this;
-  },
-
-  /**
-   * Mark position and patch `node.position`.
-   */
-
-  position: function() {
-    var start = { line: this.line, column: this.column };
-    var self = this;
-
-    return function(node) {
-      define(node, 'position', new Position(start, self));
-      return node;
-    };
-  },
-
-  /**
-   * Set parser `name` with the given `fn`
-   * @param {String} `name`
-   * @param {Function} `fn`
-   * @api public
-   */
-
-  set: function(type, fn) {
-    if (this.types.indexOf(type) === -1) {
-      this.types.push(type);
-    }
-    this.parsers[type] = fn.bind(this);
-    return this;
-  },
-
-  /**
-   * Get parser `name`
-   * @param {String} `name`
-   * @api public
-   */
-
-  get: function(name) {
-    return this.parsers[name];
-  },
-
-  /**
-   * Push a `token` onto the `type` stack.
-   *
-   * @param {String} `type`
-   * @return {Object} `token`
-   * @api public
-   */
-
-  push: function(type, token) {
-    this.sets[type] = this.sets[type] || [];
-    this.count++;
-    this.stack.push(token);
-    return this.sets[type].push(token);
-  },
-
-  /**
-   * Pop a token off of the `type` stack
-   * @param {String} `type`
-   * @returns {Object} Returns a token
-   * @api public
-   */
-
-  pop: function(type) {
-    this.sets[type] = this.sets[type] || [];
-    this.count--;
-    this.stack.pop();
-    return this.sets[type].pop();
-  },
-
-  /**
-   * Return true if inside a `stack` node. Types are `braces`, `parens` or `brackets`.
-   *
-   * @param {String} `type`
-   * @return {Boolean}
-   * @api public
-   */
-
-  isInside: function(type) {
-    this.sets[type] = this.sets[type] || [];
-    return this.sets[type].length > 0;
-  },
-
-  /**
-   * Return true if `node` is the given `type`.
-   *
-   * ```js
-   * parser.isType(node, 'brace');
-   * ```
-   * @param {Object} `node`
-   * @param {String} `type`
-   * @return {Boolean}
-   * @api public
-   */
-
-  isType: function(node, type) {
-    return node && node.type === type;
-  },
-
-  /**
-   * Get the previous AST node
-   * @return {Object}
-   */
-
-  prev: function(n) {
-    return this.stack.length > 0
-      ? utils.last(this.stack, n)
-      : utils.last(this.nodes, n);
-  },
-
-  /**
-   * Update line and column based on `str`.
-   */
-
-  consume: function(len) {
-    this.input = this.input.substr(len);
-  },
-
-  /**
-   * Update column based on `str`.
-   */
-
-  updatePosition: function(str, len) {
-    var lines = str.match(/\n/g);
-    if (lines) this.line += lines.length;
-    var i = str.lastIndexOf('\n');
-    this.column = ~i ? len - i : this.column + len;
-    this.parsed += str;
-    this.consume(len);
-  },
-
-  /**
-   * Match `regex`, return captures, and update the cursor position by `match[0]` length.
-   * @param {RegExp} `regex`
-   * @return {Object}
-   */
-
-  match: function(regex) {
-    var m = regex.exec(this.input);
-    if (m) {
-      this.updatePosition(m[0], m[0].length);
-      return m;
-    }
-  },
-
-  /**
-   * Capture `type` with the given regex.
-   * @param {String} `type`
-   * @param {RegExp} `regex`
-   * @return {Function}
-   */
-
-  capture: function(type, regex) {
-    if (typeof regex === 'function') {
-      return this.set.apply(this, arguments);
-    }
-
-    this.regex.set(type, regex);
-    this.set(type, function() {
-      var parsed = this.parsed;
-      var pos = this.position();
-      var m = this.match(regex);
-      if (!m || !m[0]) return;
-
-      var prev = this.prev();
-      var node = pos({
-        type: type,
-        val: m[0],
-        parsed: parsed,
-        rest: this.input
-      });
-
-      if (m[1]) {
-        node.inner = m[1];
-      }
-
-      define(node, 'inside', this.stack.length > 0);
-      define(node, 'parent', prev);
-      prev.nodes.push(node);
-    }.bind(this));
-    return this;
-  },
-
-  /**
-   * Create a parser with open and close for parens,
-   * brackets or braces
-   */
-
-  capturePair: function(type, openRegex, closeRegex, fn) {
-    this.sets[type] = this.sets[type] || [];
-
-    /**
-     * Open
-     */
-
-    this.set(type + '.open', function() {
-      var parsed = this.parsed;
-      var pos = this.position();
-      var m = this.match(openRegex);
-      if (!m || !m[0]) return;
-
-      var val = m[0];
-      this.setCount++;
-      this.specialChars = true;
-      var open = pos({
-        type: type + '.open',
-        val: val,
-        rest: this.input
-      });
-
-      if (typeof m[1] !== 'undefined') {
-        open.inner = m[1];
-      }
-
-      var prev = this.prev();
-      var node = pos({
-        type: type,
-        nodes: [open]
-      });
-
-      define(node, 'rest', this.input);
-      define(node, 'parsed', parsed);
-      define(node, 'prefix', m[1]);
-      define(node, 'parent', prev);
-      define(open, 'parent', node);
-
-      if (typeof fn === 'function') {
-        fn.call(this, open, node);
-      }
-
-      this.push(type, node);
-      prev.nodes.push(node);
-    });
-
-    /**
-     * Close
-     */
-
-    this.set(type + '.close', function() {
-      var pos = this.position();
-      var m = this.match(closeRegex);
-      if (!m || !m[0]) return;
-
-      var parent = this.pop(type);
-      var node = pos({
-        type: type + '.close',
-        rest: this.input,
-        suffix: m[1],
-        val: m[0]
-      });
-
-      if (!this.isType(parent, type)) {
-        if (this.options.strict) {
-          throw new Error('missing opening "' + type + '"');
-        }
-
-        this.setCount--;
-        node.escaped = true;
-        return node;
-      }
-
-      if (node.suffix === '\\') {
-        parent.escaped = true;
-        node.escaped = true;
-      }
-
-      parent.nodes.push(node);
-      define(node, 'parent', parent);
-    });
-
-    return this;
-  },
-
-  /**
-   * Capture end-of-string
-   */
-
-  eos: function() {
-    var pos = this.position();
-    if (this.input) return;
-    var prev = this.prev();
-
-    while (prev.type !== 'root' && !prev.visited) {
-      if (this.options.strict === true) {
-        throw new SyntaxError('invalid syntax:' + util.inspect(prev, null, 2));
-      }
-
-      if (!hasDelims(prev)) {
-        prev.parent.escaped = true;
-        prev.escaped = true;
-      }
-
-      visit(prev, function(node) {
-        if (!hasDelims(node.parent)) {
-          node.parent.escaped = true;
-          node.escaped = true;
-        }
-      });
-
-      prev = prev.parent;
-    }
-
-    var tok = pos({
-      type: 'eos',
-      val: this.append || ''
-    });
-
-    define(tok, 'parent', this.ast);
-    return tok;
-  },
-
-  /**
-   * Run parsers to advance the cursor position
-   */
-
-  next: function() {
-    var parsed = this.parsed;
-    var len = this.types.length;
-    var idx = -1;
-    var tok;
-
-    while (++idx < len) {
-      if ((tok = this.parsers[this.types[idx]].call(this))) {
-        define(tok, 'rest', this.input);
-        define(tok, 'parsed', parsed);
-        this.last = tok;
-        return tok;
-      }
-    }
-  },
-
-  /**
-   * Parse the given string.
-   * @return {Array}
-   */
-
-  parse: function(input) {
-    if (typeof input !== 'string') {
-      throw new TypeError('expected a string');
-    }
-
-    this.init(this.options);
-    this.orig = input;
-    this.input = input;
-    var self = this;
-
-    function parse() {
-      // check input before calling `.next()`
-      input = self.input;
-
-      // get the next AST ndoe
-      var node = self.next();
-      if (node) {
-        var prev = self.prev();
-        if (prev) {
-          define(node, 'parent', prev);
-          if (prev.nodes) {
-            prev.nodes.push(node);
-          }
-        }
-
-        if (self.sets.hasOwnProperty(prev.type)) {
-          self.currentType = prev.type;
-        }
-      }
-
-      // if we got here but input is not changed, throw an error
-      if (self.input && input === self.input) {
-        throw new Error('no parsers registered for: "' + self.input.slice(0, 5) + '"');
-      }
-    }
-
-    while (this.input) parse();
-    if (this.stack.length && this.options.strict) {
-      var node = this.stack.pop();
-      throw this.error('missing opening ' + node.type + ': "' + this.orig + '"');
-    }
-
-    var eos = this.eos();
-    var tok = this.prev();
-    if (tok.type !== 'eos') {
-      this.ast.nodes.push(eos);
-    }
-
-    return this.ast;
-  }
-};
-
-/**
- * Visit `node` with the given `fn`
- */
-
-function visit(node, fn) {
-  if (!node.visited) {
-    define(node, 'visited', true);
-    return node.nodes ? mapVisit(node.nodes, fn) : fn(node);
-  }
-  return node;
-}
-
-/**
- * Map visit over array of `nodes`.
- */
-
-function mapVisit(nodes, fn) {
-  var len = nodes.length;
-  var idx = -1;
-  while (++idx < len) {
-    visit(nodes[idx], fn);
-  }
-}
-
-function hasOpen(node) {
-  return node.nodes && node.nodes[0].type === (node.type + '.open');
-}
-
-function hasClose(node) {
-  return node.nodes && utils.last(node.nodes).type === (node.type + '.close');
-}
-
-function hasDelims(node) {
-  return hasOpen(node) && hasClose(node);
-}
-
-/**
- * Expose `Parser`
- */
-
-module.exports = Parser;

+ 0 - 14
node_modules.bak/snapdragon/lib/position.js

@@ -1,14 +0,0 @@
-'use strict';
-
-var define = require('define-property');
-
-/**
- * Store position for a node
- */
-
-module.exports = function Position(start, parser) {
-  this.start = start;
-  this.end = { line: parser.line, column: parser.column };
-  define(this, 'content', parser.orig);
-  define(this, 'source', parser.options.source);
-};

+ 0 - 145
node_modules.bak/snapdragon/lib/source-maps.js

@@ -1,145 +0,0 @@
-'use strict';
-
-var fs = require('fs');
-var path = require('path');
-var define = require('define-property');
-var utils = require('./utils');
-
-/**
- * Expose `mixin()`.
- * This code is based on `source-maps-support.js` in reworkcss/css
- * https://github.com/reworkcss/css/blob/master/lib/stringify/source-map-support.js
- * Copyright (c) 2012 TJ Holowaychuk <tj@vision-media.ca>
- */
-
-module.exports = mixin;
-
-/**
- * Mixin source map support into `compiler`.
- *
- * @param {Object} `compiler`
- * @api public
- */
-
-function mixin(compiler) {
-  define(compiler, '_comment', compiler.comment);
-  compiler.map = new utils.SourceMap.SourceMapGenerator();
-  compiler.position = { line: 1, column: 1 };
-  compiler.content = {};
-  compiler.files = {};
-
-  for (var key in exports) {
-    define(compiler, key, exports[key]);
-  }
-}
-
-/**
- * Update position.
- *
- * @param {String} str
- */
-
-exports.updatePosition = function(str) {
-  var lines = str.match(/\n/g);
-  if (lines) this.position.line += lines.length;
-  var i = str.lastIndexOf('\n');
-  this.position.column = ~i ? str.length - i : this.position.column + str.length;
-};
-
-/**
- * Emit `str` with `position`.
- *
- * @param {String} str
- * @param {Object} [pos]
- * @return {String}
- */
-
-exports.emit = function(str, node) {
-  var position = node.position || {};
-  var source = position.source;
-  if (source) {
-    if (position.filepath) {
-      source = utils.unixify(position.filepath);
-    }
-
-    this.map.addMapping({
-      source: source,
-      generated: {
-        line: this.position.line,
-        column: Math.max(this.position.column - 1, 0)
-      },
-      original: {
-        line: position.start.line,
-        column: position.start.column - 1
-      }
-    });
-
-    if (position.content) {
-      this.addContent(source, position);
-    }
-    if (position.filepath) {
-      this.addFile(source, position);
-    }
-
-    this.updatePosition(str);
-    this.output += str;
-  }
-  return str;
-};
-
-/**
- * Adds a file to the source map output if it has not already been added
- * @param {String} `file`
- * @param {Object} `pos`
- */
-
-exports.addFile = function(file, position) {
-  if (typeof position.content !== 'string') return;
-  if (Object.prototype.hasOwnProperty.call(this.files, file)) return;
-  this.files[file] = position.content;
-};
-
-/**
- * Adds a content source to the source map output if it has not already been added
- * @param {String} `source`
- * @param {Object} `position`
- */
-
-exports.addContent = function(source, position) {
-  if (typeof position.content !== 'string') return;
-  if (Object.prototype.hasOwnProperty.call(this.content, source)) return;
-  this.map.setSourceContent(source, position.content);
-};
-
-/**
- * Applies any original source maps to the output and embeds the source file
- * contents in the source map.
- */
-
-exports.applySourceMaps = function() {
-  Object.keys(this.files).forEach(function(file) {
-    var content = this.files[file];
-    this.map.setSourceContent(file, content);
-
-    if (this.options.inputSourcemaps === true) {
-      var originalMap = utils.sourceMapResolve.resolveSync(content, file, fs.readFileSync);
-      if (originalMap) {
-        var map = new utils.SourceMap.SourceMapConsumer(originalMap.map);
-        var relativeTo = originalMap.sourcesRelativeTo;
-        this.map.applySourceMap(map, file, utils.unixify(path.dirname(relativeTo)));
-      }
-    }
-  }, this);
-};
-
-/**
- * Process comments, drops sourceMap comments.
- * @param {Object} node
- */
-
-exports.comment = function(node) {
-  if (/^# sourceMappingURL=/.test(node.comment)) {
-    return this.emit('', node.position);
-  }
-  return this._comment(node);
-};

+ 0 - 48
node_modules.bak/snapdragon/lib/utils.js

@@ -1,48 +0,0 @@
-'use strict';
-
-/**
- * Module dependencies
- */
-
-exports.extend = require('extend-shallow');
-exports.SourceMap = require('source-map');
-exports.sourceMapResolve = require('source-map-resolve');
-
-/**
- * Convert backslash in the given string to forward slashes
- */
-
-exports.unixify = function(fp) {
-  return fp.split(/\\+/).join('/');
-};
-
-/**
- * Return true if `val` is a non-empty string
- *
- * @param {String} `str`
- * @return {Boolean}
- */
-
-exports.isString = function(str) {
-  return str && typeof str === 'string';
-};
-
-/**
- * Cast `val` to an array
- * @return {Array}
- */
-
-exports.arrayify = function(val) {
-  if (typeof val === 'string') return [val];
-  return val ? (Array.isArray(val) ? val : [val]) : [];
-};
-
-/**
- * Get the last `n` element from the given `array`
- * @param {Array} `array`
- * @return {*}
- */
-
-exports.last = function(arr, n) {
-  return arr[arr.length - (n || 1)];
-};

+ 0 - 126
node_modules.bak/snapdragon/package.json

@@ -1,126 +0,0 @@
-{
-  "_from": "snapdragon@^0.8.1",
-  "_id": "snapdragon@0.8.2",
-  "_inBundle": false,
-  "_integrity": "sha1-ZJIufFZbDhQgS6GqfWlkJ40lGC0=",
-  "_location": "/snapdragon",
-  "_phantomChildren": {
-    "is-descriptor": "0.1.6",
-    "is-extendable": "0.1.1"
-  },
-  "_requested": {
-    "type": "range",
-    "registry": true,
-    "raw": "snapdragon@^0.8.1",
-    "name": "snapdragon",
-    "escapedName": "snapdragon",
-    "rawSpec": "^0.8.1",
-    "saveSpec": null,
-    "fetchSpec": "^0.8.1"
-  },
-  "_requiredBy": [
-    "/braces",
-    "/expand-brackets",
-    "/extglob",
-    "/micromatch",
-    "/nanomatch"
-  ],
-  "_resolved": "https://registry.npm.taobao.org/snapdragon/download/snapdragon-0.8.2.tgz?cache=0&sync_timestamp=1617971785350&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fsnapdragon%2Fdownload%2Fsnapdragon-0.8.2.tgz",
-  "_shasum": "64922e7c565b0e14204ba1aa7d6964278d25182d",
-  "_spec": "snapdragon@^0.8.1",
-  "_where": "D:\\朗通信息\\icssDService\\node_modules\\micromatch",
-  "author": {
-    "name": "Jon Schlinkert",
-    "url": "https://github.com/jonschlinkert"
-  },
-  "bugs": {
-    "url": "https://github.com/jonschlinkert/snapdragon/issues"
-  },
-  "bundleDependencies": false,
-  "contributors": [
-    {
-      "name": "Brian Woodward",
-      "url": "https://twitter.com/doowb"
-    },
-    {
-      "name": "Edward Betts",
-      "url": "http://edwardbetts.com"
-    },
-    {
-      "name": "Jon Schlinkert",
-      "url": "http://twitter.com/jonschlinkert"
-    }
-  ],
-  "dependencies": {
-    "base": "^0.11.1",
-    "debug": "^2.2.0",
-    "define-property": "^0.2.5",
-    "extend-shallow": "^2.0.1",
-    "map-cache": "^0.2.2",
-    "source-map": "^0.5.6",
-    "source-map-resolve": "^0.5.0",
-    "use": "^3.1.0"
-  },
-  "deprecated": false,
-  "description": "Fast, pluggable and easy-to-use parser-renderer factory.",
-  "devDependencies": {
-    "gulp": "^3.9.1",
-    "gulp-eslint": "^3.0.1",
-    "gulp-format-md": "^0.1.10",
-    "gulp-istanbul": "^1.1.1",
-    "gulp-mocha": "^3.0.1",
-    "gulp-unused": "^0.2.0",
-    "mocha": "^3.0.2"
-  },
-  "engines": {
-    "node": ">=0.10.0"
-  },
-  "files": [
-    "index.js",
-    "lib"
-  ],
-  "homepage": "https://github.com/jonschlinkert/snapdragon",
-  "keywords": [
-    "lexer",
-    "snapdragon"
-  ],
-  "license": "MIT",
-  "main": "index.js",
-  "name": "snapdragon",
-  "repository": {
-    "type": "git",
-    "url": "git+https://github.com/jonschlinkert/snapdragon.git"
-  },
-  "scripts": {
-    "test": "mocha"
-  },
-  "verb": {
-    "toc": false,
-    "layout": "default",
-    "tasks": [
-      "readme"
-    ],
-    "plugins": [
-      "gulp-format-md"
-    ],
-    "related": {
-      "description": "These libraries use snapdragon:",
-      "list": [
-        "braces",
-        "expand-brackets",
-        "extglob",
-        "micromatch"
-      ]
-    },
-    "reflinks": [
-      "css",
-      "pug",
-      "verb",
-      "verb-generate-readme"
-    ],
-    "lint": {
-      "reflinks": true
-    }
-  },
-  "version": "0.8.2"
-}

+ 0 - 10
node_modules.bak/sockjs-client/AUTHORS

@@ -1,10 +0,0 @@
-# This is the list of sockjs-client authors for copyright purposes.
-#
-# This does not necessarily list everyone who has contributed code, since in
-# some cases, their employer may be the copyright holder.  To see the full list
-# of contributors, see the revision history in source control.
-Bryce Kahle
-Marek Majkowski
-VMWare
-LearnBoost
-Julian Aubourg

+ 0 - 76
node_modules.bak/sockjs-client/CODE_OF_CONDUCT.md

@@ -1,76 +0,0 @@
-# Contributor Covenant Code of Conduct
-
-## Our Pledge
-
-In the interest of fostering an open and welcoming environment, we as
-contributors and maintainers pledge to making participation in our project and
-our community a harassment-free experience for everyone, regardless of age, body
-size, disability, ethnicity, sex characteristics, gender identity and expression,
-level of experience, education, socio-economic status, nationality, personal
-appearance, race, religion, or sexual identity and orientation.
-
-## Our Standards
-
-Examples of behavior that contributes to creating a positive environment
-include:
-
-* Using welcoming and inclusive language
-* Being respectful of differing viewpoints and experiences
-* Gracefully accepting constructive criticism
-* Focusing on what is best for the community
-* Showing empathy towards other community members
-
-Examples of unacceptable behavior by participants include:
-
-* The use of sexualized language or imagery and unwelcome sexual attention or
- advances
-* Trolling, insulting/derogatory comments, and personal or political attacks
-* Public or private harassment
-* Publishing others' private information, such as a physical or electronic
- address, without explicit permission
-* Other conduct which could reasonably be considered inappropriate in a
- professional setting
-
-## Our Responsibilities
-
-Project maintainers are responsible for clarifying the standards of acceptable
-behavior and are expected to take appropriate and fair corrective action in
-response to any instances of unacceptable behavior.
-
-Project maintainers have the right and responsibility to remove, edit, or
-reject comments, commits, code, wiki edits, issues, and other contributions
-that are not aligned to this Code of Conduct, or to ban temporarily or
-permanently any contributor for other behaviors that they deem inappropriate,
-threatening, offensive, or harmful.
-
-## Scope
-
-This Code of Conduct applies both within project spaces and in public spaces
-when an individual is representing the project or its community. Examples of
-representing a project or community include using an official project e-mail
-address, posting via an official social media account, or acting as an appointed
-representative at an online or offline event. Representation of a project may be
-further defined and clarified by project maintainers.
-
-## Enforcement
-
-Instances of abusive, harassing, or otherwise unacceptable behavior may be
-reported by contacting the project team at sockjs@brycekahle.com. All
-complaints will be reviewed and investigated and will result in a response that
-is deemed necessary and appropriate to the circumstances. The project team is
-obligated to maintain confidentiality with regard to the reporter of an incident.
-Further details of specific enforcement policies may be posted separately.
-
-Project maintainers who do not follow or enforce the Code of Conduct in good
-faith may face temporary or permanent repercussions as determined by other
-members of the project's leadership.
-
-## Attribution
-
-This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
-available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
-
-[homepage]: https://www.contributor-covenant.org
-
-For answers to common questions about this code of conduct, see
-https://www.contributor-covenant.org/faq

+ 0 - 327
node_modules.bak/sockjs-client/Changelog.md

@@ -1,327 +0,0 @@
-1.5.1
-==
- * Update `url-parse` due to CVE-2021-27515.
-
-1.5.0
-==
- * Update `url-parse`, `kind-of`, `minimist`, `websocket-extensions` due to security vulnerabilies.
- * Update dev dependencies.
- * Allow loopback address hostnames on a secure page. Fixes #486
- * Enable eventsource transport for node.js clients.
-
-1.4.0
-==
- * Add `timeout` option to set a minimum transport timeout. Fixes #403
- * Update dev deps to fix security warnings from `npm audit`
- * Guard against null `this._transport` in `debug` statement. Fixes #448
-
-1.3.0
-==
- * Revert `debug` to `^3` because v4 starts using ES6. Fixes #457
-
-1.2.0
-==
- * Update all outdated dependencies
- * Switch to karma and browserstack for running automated browser tests
-
-1.1.5
-==
- * Wrap the the contentWindow access in a try/catch block when in setTimeout #363
- * Revised example in README #356
- * Fix connection close when Transport timeout #358
- * Fixed crash with react-native@0.45.1 on Android #386
- * Update jsDelivr link #404, #405
- * Remove Sauce Labs unsupported browsers
- * Add link to rust server implementation #411
- * location.protocol should include final `:` #396
-
-1.1.4
-==
- * Upgrade `debug` and fix object key literal mangling, fixes regression in Opera 11.10 #359
- * Trim descriptions in package.json and bower.json - #372
-
-1.1.3
-==
-  * Bad publish to NPM (removed)
-
-1.1.2
-==
-
- * Ensure both sender and receiver are cleaned upon close - #342
- * Remove event listeners before calling `close` - #344
- * Update documentation links - #351, #339, #316
- * Explicitly export `undefined` when `WebSocket` does not exist. Fixes Webpack. #321
- * Include `dist` folder on npm - #265
- * Simplify build setup
- * Update to Node.js 6.9
- * Add sourcemap for minified version
- * Remove unused String.trim shim
-
-1.1.1
-==
-
- * Do not pass `protocols` or `options` arguments to browser WebSocket constructor - #309
-
-1.1.0
-==
-
- * Fix IE7/8 usage of `console.log` which does not have `apply` - #279
- * Remove `dbg` global variable - #282
- * Bump `faye-websocket` version to `0.11.0` - #267
- * Optimize `arguments` usage - #263
- * Add sourcemap file to dist folder - #237
- * Add way to transparently pass transport-specific options - #272
-
-1.0.3
-==
-
- * Use `https` module for xhr requests in node when url uses https - #254
-
-1.0.2
-==
-
- * Fix iframe info receiver url
- * Move iframe.contentWindow check inside setTimeout - #246
-
-1.0.1
-==
-
- * Use proper base url for iframe-based info receiver - #249
- * Don't register unload event in chrome packaged app - #223
- * Allow custom session ids - #250
- * Remove version property from bower.json - #247
- * Update example CDN url - #244
-
-1.0.0
-===
-
- * Simplify url handling by delegating to `url-parse` - #242
- * Upgrade to `url-parse` 1.0.1 to fix colon issue if auth has no password
-
-1.0.0-beta.13
-===
-
- * Transport timeout on connection should fallback - #238
-
-1.0.0-beta.12
-====
-
- * Upgrade `url-parse` to 1.0.0 to fix #218 again
-
-1.0.0-beta.10
-====
-
- * Upgrade `url-parse` to 0.2.3 to fix #222
-
-1.0.0-beta.9
-====
-
- * Upgrade `url-parse` to 0.2.1 to fix 'too much recursion' errors
-
-1.0.0-beta.8
-====
-
- * Upgrade `url-parse` to 0.2.0 to fix inheritance issues
-
-1.0.0-beta.7
-====
-
- * Upgrade `url-parse` to 0.1.5 to fix #218
- * Don't strip basic auth from url - #219
-
-1.0.0-beta.6
-====
-
- * Upgrade `url-parse` to 0.1.3 to avoid CSP issues
-
-1.0.0-beta.5
-=====
-
- * Upgrade `url-parse` to 0.1.1 to fix #214
-
-1.0.0-beta.4
-=====
-
- * Upgrade `url-parse` to 0.1.0 and `sockjs` to 0.3.11
- * Update .npmignore
-
-1.0.0-beta.3
-=====
-
- * Move `debug` from devDependencies to dependencies
-
-1.0.0-beta.2
-=====
-
- * Relax requirements when using same origin XHR - #80
- * Upgrade to JSON3 from JSON2 - #123
- * Package library with browserify supporting the UMD pattern - #184
- * Move tests to JavaScript
- * Add Gulp.js build script
- * Fix getOrigin for file:/// urls and standard ports - #173
- * Add onerror event handlers to Websockets - #169
- * Increase RTO lower bound to prevent spurious timeouts on IE8/9 - #161
- * Use window.crypto for random values when available - #128
- * Fix handling of listeners added and removed mid-dispatch - #127
- * Fix XHR Streaming for IE8 - #83
- * Remove explicit AMD name - #107
- * Check for an empty response from /info request - #143
- * Add Content-Type to XHR requests to fix issue over HTTPS on Galaxy S4 - #164
- * Fix iframe fallback when message is sent from a popup in IE7/8 - #166
- * Add support for query strings on the url - #72
- * Now works inside of Web Workers - #181
- * Support EventSource / Server Sent Events outside of iframes - #201
- * Rename protocols to transports - #65
- * Allow transports which need the body to trigger on 'interactive' readyState - #175
- * try/catch access to document.domain - #187
- * Use `window.location` instead of `document.location` - #195
- * Allow usage from node.js with same API
-
-0.3.4
-=====
-
- * Mentioned njoyce's fork of sockjs-gevent.
- * #90 - Don't catch onbeforeunload event - it breaks javascript://
-   links in IE.
- * IE mangles 204 response code for 1223 on ajax, see:
-   http://bugs.jquery.com/ticket/1450
- * Make `new` optional for SockJS constructor (via substack).
- * It is impossible to cancel JSONP polling request - compensate for that.
- * Refactored EventEmitter prototype (used only internally)
- * #66 - Failure to post data to /xhr_send should kill the session
-
-
-0.3.2
-=====
-
- * #77 - Getting /info on modern browsers when html is served from
-         file:// urls was broken.
-
-0.3.1
-=====
-
- * #61 - Meteor guys found that we unintentionally catch "onopen" errors.
- * #63 - Meteorjs guys found that xhr-streaming on Safari sometimes
-   left busy cursor running.
- * Increased allowed time for websocket transport (from 1 rtt to 2),
-   this should make ws transport more reliable over SSL, at the cost
-   of slightly longer connection time for users with blocked ws.
- * #57 - previous fix didn't really work, sockjs-client still left
-   a mess in browsers history when using iframe transports. This
-   is fixed now.
- * #60 - Opera 12 (next) claims to do AJAX2 / CORS, but can't
-   do xhr-streaming.
- * #58 - onunload test sometimes failed on Safari on windows
- * Updated readme WRT websocket protocols
- * Updated readme WRT deployments on heroku
- * Add minimalistic license block to every source file.
-
-
-0.3.0
-=====
-
- * Temporarily disabled iframe tests - they are failing unpredictably.
- * #57 - pointing an iframe to "about:blank" during cleanup caused
-   Opera to messup history.
- * #55 - Improved iframe abstraction (reduced a possible mem leak)
- * Refactored AJAX abstractions, for better CORS handing - again.
- * Add additional parent origin security check to an iframe.
- * Urls with hashes or query strings can't be passed to SockJS.
- * #18 - Mention workaround for Firefox ESC key issue
- * #53 - AMD compliance
- * sockjs/sockjs-protocol#28 - always use square brackets for
-   websocket frames
- * #51 - initial support for IE10 - try XHR before XDR
- * #28 - handle onunload / onbeforeunload in a more robust fashion
- * #49 - support SockJS-client being used from files served from
-   file:// urls.
-
-
-0.2.1
-=====
-
- * "smoke-latency.html" test was unnecesairly sending too much data.
- * Bumped core dependencies (coffee-script and uglify-js)
- * Minor updates to the README, few cosmetic changes in the code.
-
-
-0.2.0
-=====
-
- * The API had changed - use `protocols_whitelist` option instead of
-   passing  an array of protocols as a second argument to SockJS constructor.
- * Dropped 'chunking-test' functionality and replace it with 'info'.
- * Rewritten protocol-choosing alogirthm, see "utils.detectProtocols" method.
- * Use dynamic protocol timeouts based on RTT, not hardcoded 5 seconds
- * #34 - Don't ever reuse `session_id`, especially when trying
-   fallback protocols.
- * The test server got moved from SockJS-client to SockJS-node.
- * Don't test unicode surrogates - it can't work in some environments.
- * XHR/XDR helpers were rewritten, ajax transports were simplified.
- * Added a domain check in the iframe to improve security.
- * SockJS will now trigger 1002 error if there is a problem during handshake
-   instead of 2000 error.
- * Smoke-throughput test is renamed to smoke-latency.
-
-0.1.2
-=====
-
- * #29 - Allow all unicode characters to be send over SockJS.
- * #15 - SockJS should now work fine even if the connection is started
-   in HEAD, before BODY is loaded.
- * #28 - In rare circumstances WebSocket connection can be left intact
-   after the page is unloaded in FireFox.
- * Updated scripts to work with Node 0.6.
- * Initial work to do better QUnit testing.
- * Updated the minifying script (always escape unicode chars, remove
-   trailing comment).
- * Use string instead of array of chars (utils.js:random_number_string).
-
-
-0.1.1
-=====
-
- * #21 Get JsonP transport working on IE9 (Vladimir Dronnikov).
- * #26 Emit heartbeat event.
- * #27 Include license inline.
-
-
-0.1.0
-=====
-
- * SockJS-client can only send UTF-8 encodable strings.  Previously we
-   took advantage of rich data structures and automatically
-   json-encoded them, but this got removed.  Now, all data passed to
-   `send` will be converted to string. This is also how native
- * `status` property on `EventClose` is renamed to `code`
-   as per Websocket API
-   WebSockets behave.
- * The test server was updated to new `sockjs-node` API
- * Fixed problem with Jsonp-polling transport on IE9
- * Repository was moved - updated links.
-
-
-0.0.4
-=====
-
- * All transports were refactored, some transports were introduced:
-   htmlfile and separate xhr-streaming.
- * Added logic to detect support for http chunking, and thus a
-   possibility to rule out streaming transports before running them.
- * Added 'cookie' option, useful for cookie-based load balancing
-   (currently, it make a difference only for IE).
- * Added hack to prevent EventSource from crashing Safari and Chrome.
- * Loads and loads of other small and medium changes.
-
-
-0.0.2
-=====
-
- * Initial support for JSESSIONID based load balancing. Currently
-   doesn't play nicely with IE XDomainRequest transport.
-
-
-0.0.1
-=====
-
- * Initial release.

+ 0 - 21
node_modules.bak/sockjs-client/LICENSE

@@ -1,21 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) 2011-2018 The sockjs-client Authors.
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.

文件差异内容过多而无法显示
+ 0 - 354
node_modules.bak/sockjs-client/README.md


+ 0 - 10
node_modules.bak/sockjs-client/lib/entry.js

@@ -1,10 +0,0 @@
-'use strict';
-
-var transportList = require('./transport-list');
-
-module.exports = require('./main')(transportList);
-
-// TODO can't get rid of this until all servers do
-if ('_sockjs_onload' in global) {
-  setTimeout(global._sockjs_onload, 1);
-}

+ 0 - 17
node_modules.bak/sockjs-client/lib/event/close.js

@@ -1,17 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , Event = require('./event')
-  ;
-
-function CloseEvent() {
-  Event.call(this);
-  this.initEvent('close', false, false);
-  this.wasClean = false;
-  this.code = 0;
-  this.reason = '';
-}
-
-inherits(CloseEvent, Event);
-
-module.exports = CloseEvent;

+ 0 - 57
node_modules.bak/sockjs-client/lib/event/emitter.js

@@ -1,57 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , EventTarget = require('./eventtarget')
-  ;
-
-function EventEmitter() {
-  EventTarget.call(this);
-}
-
-inherits(EventEmitter, EventTarget);
-
-EventEmitter.prototype.removeAllListeners = function(type) {
-  if (type) {
-    delete this._listeners[type];
-  } else {
-    this._listeners = {};
-  }
-};
-
-EventEmitter.prototype.once = function(type, listener) {
-  var self = this
-    , fired = false;
-
-  function g() {
-    self.removeListener(type, g);
-
-    if (!fired) {
-      fired = true;
-      listener.apply(this, arguments);
-    }
-  }
-
-  this.on(type, g);
-};
-
-EventEmitter.prototype.emit = function() {
-  var type = arguments[0];
-  var listeners = this._listeners[type];
-  if (!listeners) {
-    return;
-  }
-  // equivalent of Array.prototype.slice.call(arguments, 1);
-  var l = arguments.length;
-  var args = new Array(l - 1);
-  for (var ai = 1; ai < l; ai++) {
-    args[ai - 1] = arguments[ai];
-  }
-  for (var i = 0; i < listeners.length; i++) {
-    listeners[i].apply(this, args);
-  }
-};
-
-EventEmitter.prototype.on = EventEmitter.prototype.addListener = EventTarget.prototype.addEventListener;
-EventEmitter.prototype.removeListener = EventTarget.prototype.removeEventListener;
-
-module.exports.EventEmitter = EventEmitter;

+ 0 - 22
node_modules.bak/sockjs-client/lib/event/event.js

@@ -1,22 +0,0 @@
-'use strict';
-
-function Event(eventType) {
-  this.type = eventType;
-}
-
-Event.prototype.initEvent = function(eventType, canBubble, cancelable) {
-  this.type = eventType;
-  this.bubbles = canBubble;
-  this.cancelable = cancelable;
-  this.timeStamp = +new Date();
-  return this;
-};
-
-Event.prototype.stopPropagation = function() {};
-Event.prototype.preventDefault = function() {};
-
-Event.CAPTURING_PHASE = 1;
-Event.AT_TARGET = 2;
-Event.BUBBLING_PHASE = 3;
-
-module.exports = Event;

+ 0 - 62
node_modules.bak/sockjs-client/lib/event/eventtarget.js

@@ -1,62 +0,0 @@
-'use strict';
-
-/* Simplified implementation of DOM2 EventTarget.
- *   http://www.w3.org/TR/DOM-Level-2-Events/events.html#Events-EventTarget
- */
-
-function EventTarget() {
-  this._listeners = {};
-}
-
-EventTarget.prototype.addEventListener = function(eventType, listener) {
-  if (!(eventType in this._listeners)) {
-    this._listeners[eventType] = [];
-  }
-  var arr = this._listeners[eventType];
-  // #4
-  if (arr.indexOf(listener) === -1) {
-    // Make a copy so as not to interfere with a current dispatchEvent.
-    arr = arr.concat([listener]);
-  }
-  this._listeners[eventType] = arr;
-};
-
-EventTarget.prototype.removeEventListener = function(eventType, listener) {
-  var arr = this._listeners[eventType];
-  if (!arr) {
-    return;
-  }
-  var idx = arr.indexOf(listener);
-  if (idx !== -1) {
-    if (arr.length > 1) {
-      // Make a copy so as not to interfere with a current dispatchEvent.
-      this._listeners[eventType] = arr.slice(0, idx).concat(arr.slice(idx + 1));
-    } else {
-      delete this._listeners[eventType];
-    }
-    return;
-  }
-};
-
-EventTarget.prototype.dispatchEvent = function() {
-  var event = arguments[0];
-  var t = event.type;
-  // equivalent of Array.prototype.slice.call(arguments, 0);
-  var args = arguments.length === 1 ? [event] : Array.apply(null, arguments);
-  // TODO: This doesn't match the real behavior; per spec, onfoo get
-  // their place in line from the /first/ time they're set from
-  // non-null. Although WebKit bumps it to the end every time it's
-  // set.
-  if (this['on' + t]) {
-    this['on' + t].apply(this, args);
-  }
-  if (t in this._listeners) {
-    // Grab a reference to the listeners list. removeEventListener may alter the list.
-    var listeners = this._listeners[t];
-    for (var i = 0; i < listeners.length; i++) {
-      listeners[i].apply(this, args);
-    }
-  }
-};
-
-module.exports = EventTarget;

+ 0 - 15
node_modules.bak/sockjs-client/lib/event/trans-message.js

@@ -1,15 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , Event = require('./event')
-  ;
-
-function TransportMessageEvent(data) {
-  Event.call(this);
-  this.initEvent('message', false, false);
-  this.data = data;
-}
-
-inherits(TransportMessageEvent, Event);
-
-module.exports = TransportMessageEvent;

+ 0 - 27
node_modules.bak/sockjs-client/lib/facade.js

@@ -1,27 +0,0 @@
-'use strict';
-
-var JSON3 = require('json3')
-  , iframeUtils = require('./utils/iframe')
-  ;
-
-function FacadeJS(transport) {
-  this._transport = transport;
-  transport.on('message', this._transportMessage.bind(this));
-  transport.on('close', this._transportClose.bind(this));
-}
-
-FacadeJS.prototype._transportClose = function(code, reason) {
-  iframeUtils.postMessage('c', JSON3.stringify([code, reason]));
-};
-FacadeJS.prototype._transportMessage = function(frame) {
-  iframeUtils.postMessage('t', frame);
-};
-FacadeJS.prototype._send = function(data) {
-  this._transport.send(data);
-};
-FacadeJS.prototype._close = function() {
-  this._transport.close();
-  this._transport.removeAllListeners();
-};
-
-module.exports = FacadeJS;

+ 0 - 102
node_modules.bak/sockjs-client/lib/iframe-bootstrap.js

@@ -1,102 +0,0 @@
-'use strict';
-
-var urlUtils = require('./utils/url')
-  , eventUtils = require('./utils/event')
-  , JSON3 = require('json3')
-  , FacadeJS = require('./facade')
-  , InfoIframeReceiver = require('./info-iframe-receiver')
-  , iframeUtils = require('./utils/iframe')
-  , loc = require('./location')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:iframe-bootstrap');
-}
-
-module.exports = function(SockJS, availableTransports) {
-  var transportMap = {};
-  availableTransports.forEach(function(at) {
-    if (at.facadeTransport) {
-      transportMap[at.facadeTransport.transportName] = at.facadeTransport;
-    }
-  });
-
-  // hard-coded for the info iframe
-  // TODO see if we can make this more dynamic
-  transportMap[InfoIframeReceiver.transportName] = InfoIframeReceiver;
-  var parentOrigin;
-
-  /* eslint-disable camelcase */
-  SockJS.bootstrap_iframe = function() {
-    /* eslint-enable camelcase */
-    var facade;
-    iframeUtils.currentWindowId = loc.hash.slice(1);
-    var onMessage = function(e) {
-      if (e.source !== parent) {
-        return;
-      }
-      if (typeof parentOrigin === 'undefined') {
-        parentOrigin = e.origin;
-      }
-      if (e.origin !== parentOrigin) {
-        return;
-      }
-
-      var iframeMessage;
-      try {
-        iframeMessage = JSON3.parse(e.data);
-      } catch (ignored) {
-        debug('bad json', e.data);
-        return;
-      }
-
-      if (iframeMessage.windowId !== iframeUtils.currentWindowId) {
-        return;
-      }
-      switch (iframeMessage.type) {
-      case 's':
-        var p;
-        try {
-          p = JSON3.parse(iframeMessage.data);
-        } catch (ignored) {
-          debug('bad json', iframeMessage.data);
-          break;
-        }
-        var version = p[0];
-        var transport = p[1];
-        var transUrl = p[2];
-        var baseUrl = p[3];
-        debug(version, transport, transUrl, baseUrl);
-        // change this to semver logic
-        if (version !== SockJS.version) {
-          throw new Error('Incompatible SockJS! Main site uses:' +
-                    ' "' + version + '", the iframe:' +
-                    ' "' + SockJS.version + '".');
-        }
-
-        if (!urlUtils.isOriginEqual(transUrl, loc.href) ||
-            !urlUtils.isOriginEqual(baseUrl, loc.href)) {
-          throw new Error('Can\'t connect to different domain from within an ' +
-                    'iframe. (' + loc.href + ', ' + transUrl + ', ' + baseUrl + ')');
-        }
-        facade = new FacadeJS(new transportMap[transport](transUrl, baseUrl));
-        break;
-      case 'm':
-        facade._send(iframeMessage.data);
-        break;
-      case 'c':
-        if (facade) {
-          facade._close();
-        }
-        facade = null;
-        break;
-      }
-    };
-
-    eventUtils.attachEvent('message', onMessage);
-
-    // Start
-    iframeUtils.postMessage('s');
-  };
-};

+ 0 - 49
node_modules.bak/sockjs-client/lib/info-ajax.js

@@ -1,49 +0,0 @@
-'use strict';
-
-var EventEmitter = require('events').EventEmitter
-  , inherits = require('inherits')
-  , JSON3 = require('json3')
-  , objectUtils = require('./utils/object')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:info-ajax');
-}
-
-function InfoAjax(url, AjaxObject) {
-  EventEmitter.call(this);
-
-  var self = this;
-  var t0 = +new Date();
-  this.xo = new AjaxObject('GET', url);
-
-  this.xo.once('finish', function(status, text) {
-    var info, rtt;
-    if (status === 200) {
-      rtt = (+new Date()) - t0;
-      if (text) {
-        try {
-          info = JSON3.parse(text);
-        } catch (e) {
-          debug('bad json', text);
-        }
-      }
-
-      if (!objectUtils.isObject(info)) {
-        info = {};
-      }
-    }
-    self.emit('finish', info, rtt);
-    self.removeAllListeners();
-  });
-}
-
-inherits(InfoAjax, EventEmitter);
-
-InfoAjax.prototype.close = function() {
-  this.removeAllListeners();
-  this.xo.close();
-};
-
-module.exports = InfoAjax;

+ 0 - 33
node_modules.bak/sockjs-client/lib/info-iframe-receiver.js

@@ -1,33 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , EventEmitter = require('events').EventEmitter
-  , JSON3 = require('json3')
-  , XHRLocalObject = require('./transport/sender/xhr-local')
-  , InfoAjax = require('./info-ajax')
-  ;
-
-function InfoReceiverIframe(transUrl) {
-  var self = this;
-  EventEmitter.call(this);
-
-  this.ir = new InfoAjax(transUrl, XHRLocalObject);
-  this.ir.once('finish', function(info, rtt) {
-    self.ir = null;
-    self.emit('message', JSON3.stringify([info, rtt]));
-  });
-}
-
-inherits(InfoReceiverIframe, EventEmitter);
-
-InfoReceiverIframe.transportName = 'iframe-info-receiver';
-
-InfoReceiverIframe.prototype.close = function() {
-  if (this.ir) {
-    this.ir.close();
-    this.ir = null;
-  }
-  this.removeAllListeners();
-};
-
-module.exports = InfoReceiverIframe;

+ 0 - 69
node_modules.bak/sockjs-client/lib/info-iframe.js

@@ -1,69 +0,0 @@
-'use strict';
-
-var EventEmitter = require('events').EventEmitter
-  , inherits = require('inherits')
-  , JSON3 = require('json3')
-  , utils = require('./utils/event')
-  , IframeTransport = require('./transport/iframe')
-  , InfoReceiverIframe = require('./info-iframe-receiver')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:info-iframe');
-}
-
-function InfoIframe(baseUrl, url) {
-  var self = this;
-  EventEmitter.call(this);
-
-  var go = function() {
-    var ifr = self.ifr = new IframeTransport(InfoReceiverIframe.transportName, url, baseUrl);
-
-    ifr.once('message', function(msg) {
-      if (msg) {
-        var d;
-        try {
-          d = JSON3.parse(msg);
-        } catch (e) {
-          debug('bad json', msg);
-          self.emit('finish');
-          self.close();
-          return;
-        }
-
-        var info = d[0], rtt = d[1];
-        self.emit('finish', info, rtt);
-      }
-      self.close();
-    });
-
-    ifr.once('close', function() {
-      self.emit('finish');
-      self.close();
-    });
-  };
-
-  // TODO this seems the same as the 'needBody' from transports
-  if (!global.document.body) {
-    utils.attachEvent('load', go);
-  } else {
-    go();
-  }
-}
-
-inherits(InfoIframe, EventEmitter);
-
-InfoIframe.enabled = function() {
-  return IframeTransport.enabled();
-};
-
-InfoIframe.prototype.close = function() {
-  if (this.ifr) {
-    this.ifr.close();
-  }
-  this.removeAllListeners();
-  this.ifr = null;
-};
-
-module.exports = InfoIframe;

+ 0 - 89
node_modules.bak/sockjs-client/lib/info-receiver.js

@@ -1,89 +0,0 @@
-'use strict';
-
-var EventEmitter = require('events').EventEmitter
-  , inherits = require('inherits')
-  , urlUtils = require('./utils/url')
-  , XDR = require('./transport/sender/xdr')
-  , XHRCors = require('./transport/sender/xhr-cors')
-  , XHRLocal = require('./transport/sender/xhr-local')
-  , XHRFake = require('./transport/sender/xhr-fake')
-  , InfoIframe = require('./info-iframe')
-  , InfoAjax = require('./info-ajax')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:info-receiver');
-}
-
-function InfoReceiver(baseUrl, urlInfo) {
-  debug(baseUrl);
-  var self = this;
-  EventEmitter.call(this);
-
-  setTimeout(function() {
-    self.doXhr(baseUrl, urlInfo);
-  }, 0);
-}
-
-inherits(InfoReceiver, EventEmitter);
-
-// TODO this is currently ignoring the list of available transports and the whitelist
-
-InfoReceiver._getReceiver = function(baseUrl, url, urlInfo) {
-  // determine method of CORS support (if needed)
-  if (urlInfo.sameOrigin) {
-    return new InfoAjax(url, XHRLocal);
-  }
-  if (XHRCors.enabled) {
-    return new InfoAjax(url, XHRCors);
-  }
-  if (XDR.enabled && urlInfo.sameScheme) {
-    return new InfoAjax(url, XDR);
-  }
-  if (InfoIframe.enabled()) {
-    return new InfoIframe(baseUrl, url);
-  }
-  return new InfoAjax(url, XHRFake);
-};
-
-InfoReceiver.prototype.doXhr = function(baseUrl, urlInfo) {
-  var self = this
-    , url = urlUtils.addPath(baseUrl, '/info')
-    ;
-  debug('doXhr', url);
-
-  this.xo = InfoReceiver._getReceiver(baseUrl, url, urlInfo);
-
-  this.timeoutRef = setTimeout(function() {
-    debug('timeout');
-    self._cleanup(false);
-    self.emit('finish');
-  }, InfoReceiver.timeout);
-
-  this.xo.once('finish', function(info, rtt) {
-    debug('finish', info, rtt);
-    self._cleanup(true);
-    self.emit('finish', info, rtt);
-  });
-};
-
-InfoReceiver.prototype._cleanup = function(wasClean) {
-  debug('_cleanup');
-  clearTimeout(this.timeoutRef);
-  this.timeoutRef = null;
-  if (!wasClean && this.xo) {
-    this.xo.close();
-  }
-  this.xo = null;
-};
-
-InfoReceiver.prototype.close = function() {
-  debug('close');
-  this.removeAllListeners();
-  this._cleanup(false);
-};
-
-InfoReceiver.timeout = 8000;
-
-module.exports = InfoReceiver;

+ 0 - 10
node_modules.bak/sockjs-client/lib/location.js

@@ -1,10 +0,0 @@
-'use strict';
-
-module.exports = global.location || {
-  origin: 'http://localhost:80'
-, protocol: 'http:'
-, host: 'localhost'
-, port: 80
-, href: 'http://localhost/'
-, hash: ''
-};

+ 0 - 389
node_modules.bak/sockjs-client/lib/main.js

@@ -1,389 +0,0 @@
-'use strict';
-
-require('./shims');
-
-var URL = require('url-parse')
-  , inherits = require('inherits')
-  , JSON3 = require('json3')
-  , random = require('./utils/random')
-  , escape = require('./utils/escape')
-  , urlUtils = require('./utils/url')
-  , eventUtils = require('./utils/event')
-  , transport = require('./utils/transport')
-  , objectUtils = require('./utils/object')
-  , browser = require('./utils/browser')
-  , log = require('./utils/log')
-  , Event = require('./event/event')
-  , EventTarget = require('./event/eventtarget')
-  , loc = require('./location')
-  , CloseEvent = require('./event/close')
-  , TransportMessageEvent = require('./event/trans-message')
-  , InfoReceiver = require('./info-receiver')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:main');
-}
-
-var transports;
-
-// follow constructor steps defined at http://dev.w3.org/html5/websockets/#the-websocket-interface
-function SockJS(url, protocols, options) {
-  if (!(this instanceof SockJS)) {
-    return new SockJS(url, protocols, options);
-  }
-  if (arguments.length < 1) {
-    throw new TypeError("Failed to construct 'SockJS: 1 argument required, but only 0 present");
-  }
-  EventTarget.call(this);
-
-  this.readyState = SockJS.CONNECTING;
-  this.extensions = '';
-  this.protocol = '';
-
-  // non-standard extension
-  options = options || {};
-  if (options.protocols_whitelist) {
-    log.warn("'protocols_whitelist' is DEPRECATED. Use 'transports' instead.");
-  }
-  this._transportsWhitelist = options.transports;
-  this._transportOptions = options.transportOptions || {};
-  this._timeout = options.timeout || 0;
-
-  var sessionId = options.sessionId || 8;
-  if (typeof sessionId === 'function') {
-    this._generateSessionId = sessionId;
-  } else if (typeof sessionId === 'number') {
-    this._generateSessionId = function() {
-      return random.string(sessionId);
-    };
-  } else {
-    throw new TypeError('If sessionId is used in the options, it needs to be a number or a function.');
-  }
-
-  this._server = options.server || random.numberString(1000);
-
-  // Step 1 of WS spec - parse and validate the url. Issue #8
-  var parsedUrl = new URL(url);
-  if (!parsedUrl.host || !parsedUrl.protocol) {
-    throw new SyntaxError("The URL '" + url + "' is invalid");
-  } else if (parsedUrl.hash) {
-    throw new SyntaxError('The URL must not contain a fragment');
-  } else if (parsedUrl.protocol !== 'http:' && parsedUrl.protocol !== 'https:') {
-    throw new SyntaxError("The URL's scheme must be either 'http:' or 'https:'. '" + parsedUrl.protocol + "' is not allowed.");
-  }
-
-  var secure = parsedUrl.protocol === 'https:';
-  // Step 2 - don't allow secure origin with an insecure protocol
-  if (loc.protocol === 'https:' && !secure) {
-    // exception is 127.0.0.0/8 and ::1 urls
-    if (!urlUtils.isLoopbackAddr(parsedUrl.hostname)) {
-      throw new Error('SecurityError: An insecure SockJS connection may not be initiated from a page loaded over HTTPS');
-    }
-  }
-
-  // Step 3 - check port access - no need here
-  // Step 4 - parse protocols argument
-  if (!protocols) {
-    protocols = [];
-  } else if (!Array.isArray(protocols)) {
-    protocols = [protocols];
-  }
-
-  // Step 5 - check protocols argument
-  var sortedProtocols = protocols.sort();
-  sortedProtocols.forEach(function(proto, i) {
-    if (!proto) {
-      throw new SyntaxError("The protocols entry '" + proto + "' is invalid.");
-    }
-    if (i < (sortedProtocols.length - 1) && proto === sortedProtocols[i + 1]) {
-      throw new SyntaxError("The protocols entry '" + proto + "' is duplicated.");
-    }
-  });
-
-  // Step 6 - convert origin
-  var o = urlUtils.getOrigin(loc.href);
-  this._origin = o ? o.toLowerCase() : null;
-
-  // remove the trailing slash
-  parsedUrl.set('pathname', parsedUrl.pathname.replace(/\/+$/, ''));
-
-  // store the sanitized url
-  this.url = parsedUrl.href;
-  debug('using url', this.url);
-
-  // Step 7 - start connection in background
-  // obtain server info
-  // http://sockjs.github.io/sockjs-protocol/sockjs-protocol-0.3.3.html#section-26
-  this._urlInfo = {
-    nullOrigin: !browser.hasDomain()
-  , sameOrigin: urlUtils.isOriginEqual(this.url, loc.href)
-  , sameScheme: urlUtils.isSchemeEqual(this.url, loc.href)
-  };
-
-  this._ir = new InfoReceiver(this.url, this._urlInfo);
-  this._ir.once('finish', this._receiveInfo.bind(this));
-}
-
-inherits(SockJS, EventTarget);
-
-function userSetCode(code) {
-  return code === 1000 || (code >= 3000 && code <= 4999);
-}
-
-SockJS.prototype.close = function(code, reason) {
-  // Step 1
-  if (code && !userSetCode(code)) {
-    throw new Error('InvalidAccessError: Invalid code');
-  }
-  // Step 2.4 states the max is 123 bytes, but we are just checking length
-  if (reason && reason.length > 123) {
-    throw new SyntaxError('reason argument has an invalid length');
-  }
-
-  // Step 3.1
-  if (this.readyState === SockJS.CLOSING || this.readyState === SockJS.CLOSED) {
-    return;
-  }
-
-  // TODO look at docs to determine how to set this
-  var wasClean = true;
-  this._close(code || 1000, reason || 'Normal closure', wasClean);
-};
-
-SockJS.prototype.send = function(data) {
-  // #13 - convert anything non-string to string
-  // TODO this currently turns objects into [object Object]
-  if (typeof data !== 'string') {
-    data = '' + data;
-  }
-  if (this.readyState === SockJS.CONNECTING) {
-    throw new Error('InvalidStateError: The connection has not been established yet');
-  }
-  if (this.readyState !== SockJS.OPEN) {
-    return;
-  }
-  this._transport.send(escape.quote(data));
-};
-
-SockJS.version = require('./version');
-
-SockJS.CONNECTING = 0;
-SockJS.OPEN = 1;
-SockJS.CLOSING = 2;
-SockJS.CLOSED = 3;
-
-SockJS.prototype._receiveInfo = function(info, rtt) {
-  debug('_receiveInfo', rtt);
-  this._ir = null;
-  if (!info) {
-    this._close(1002, 'Cannot connect to server');
-    return;
-  }
-
-  // establish a round-trip timeout (RTO) based on the
-  // round-trip time (RTT)
-  this._rto = this.countRTO(rtt);
-  // allow server to override url used for the actual transport
-  this._transUrl = info.base_url ? info.base_url : this.url;
-  info = objectUtils.extend(info, this._urlInfo);
-  debug('info', info);
-  // determine list of desired and supported transports
-  var enabledTransports = transports.filterToEnabled(this._transportsWhitelist, info);
-  this._transports = enabledTransports.main;
-  debug(this._transports.length + ' enabled transports');
-
-  this._connect();
-};
-
-SockJS.prototype._connect = function() {
-  for (var Transport = this._transports.shift(); Transport; Transport = this._transports.shift()) {
-    debug('attempt', Transport.transportName);
-    if (Transport.needBody) {
-      if (!global.document.body ||
-          (typeof global.document.readyState !== 'undefined' &&
-            global.document.readyState !== 'complete' &&
-            global.document.readyState !== 'interactive')) {
-        debug('waiting for body');
-        this._transports.unshift(Transport);
-        eventUtils.attachEvent('load', this._connect.bind(this));
-        return;
-      }
-    }
-
-    // calculate timeout based on RTO and round trips. Default to 5s
-    var timeoutMs = Math.max(this._timeout, (this._rto * Transport.roundTrips) || 5000);
-    this._transportTimeoutId = setTimeout(this._transportTimeout.bind(this), timeoutMs);
-    debug('using timeout', timeoutMs);
-
-    var transportUrl = urlUtils.addPath(this._transUrl, '/' + this._server + '/' + this._generateSessionId());
-    var options = this._transportOptions[Transport.transportName];
-    debug('transport url', transportUrl);
-    var transportObj = new Transport(transportUrl, this._transUrl, options);
-    transportObj.on('message', this._transportMessage.bind(this));
-    transportObj.once('close', this._transportClose.bind(this));
-    transportObj.transportName = Transport.transportName;
-    this._transport = transportObj;
-
-    return;
-  }
-  this._close(2000, 'All transports failed', false);
-};
-
-SockJS.prototype._transportTimeout = function() {
-  debug('_transportTimeout');
-  if (this.readyState === SockJS.CONNECTING) {
-    if (this._transport) {
-      this._transport.close();
-    }
-
-    this._transportClose(2007, 'Transport timed out');
-  }
-};
-
-SockJS.prototype._transportMessage = function(msg) {
-  debug('_transportMessage', msg);
-  var self = this
-    , type = msg.slice(0, 1)
-    , content = msg.slice(1)
-    , payload
-    ;
-
-  // first check for messages that don't need a payload
-  switch (type) {
-    case 'o':
-      this._open();
-      return;
-    case 'h':
-      this.dispatchEvent(new Event('heartbeat'));
-      debug('heartbeat', this.transport);
-      return;
-  }
-
-  if (content) {
-    try {
-      payload = JSON3.parse(content);
-    } catch (e) {
-      debug('bad json', content);
-    }
-  }
-
-  if (typeof payload === 'undefined') {
-    debug('empty payload', content);
-    return;
-  }
-
-  switch (type) {
-    case 'a':
-      if (Array.isArray(payload)) {
-        payload.forEach(function(p) {
-          debug('message', self.transport, p);
-          self.dispatchEvent(new TransportMessageEvent(p));
-        });
-      }
-      break;
-    case 'm':
-      debug('message', this.transport, payload);
-      this.dispatchEvent(new TransportMessageEvent(payload));
-      break;
-    case 'c':
-      if (Array.isArray(payload) && payload.length === 2) {
-        this._close(payload[0], payload[1], true);
-      }
-      break;
-  }
-};
-
-SockJS.prototype._transportClose = function(code, reason) {
-  debug('_transportClose', this.transport, code, reason);
-  if (this._transport) {
-    this._transport.removeAllListeners();
-    this._transport = null;
-    this.transport = null;
-  }
-
-  if (!userSetCode(code) && code !== 2000 && this.readyState === SockJS.CONNECTING) {
-    this._connect();
-    return;
-  }
-
-  this._close(code, reason);
-};
-
-SockJS.prototype._open = function() {
-  debug('_open', this._transport && this._transport.transportName, this.readyState);
-  if (this.readyState === SockJS.CONNECTING) {
-    if (this._transportTimeoutId) {
-      clearTimeout(this._transportTimeoutId);
-      this._transportTimeoutId = null;
-    }
-    this.readyState = SockJS.OPEN;
-    this.transport = this._transport.transportName;
-    this.dispatchEvent(new Event('open'));
-    debug('connected', this.transport);
-  } else {
-    // The server might have been restarted, and lost track of our
-    // connection.
-    this._close(1006, 'Server lost session');
-  }
-};
-
-SockJS.prototype._close = function(code, reason, wasClean) {
-  debug('_close', this.transport, code, reason, wasClean, this.readyState);
-  var forceFail = false;
-
-  if (this._ir) {
-    forceFail = true;
-    this._ir.close();
-    this._ir = null;
-  }
-  if (this._transport) {
-    this._transport.close();
-    this._transport = null;
-    this.transport = null;
-  }
-
-  if (this.readyState === SockJS.CLOSED) {
-    throw new Error('InvalidStateError: SockJS has already been closed');
-  }
-
-  this.readyState = SockJS.CLOSING;
-  setTimeout(function() {
-    this.readyState = SockJS.CLOSED;
-
-    if (forceFail) {
-      this.dispatchEvent(new Event('error'));
-    }
-
-    var e = new CloseEvent('close');
-    e.wasClean = wasClean || false;
-    e.code = code || 1000;
-    e.reason = reason;
-
-    this.dispatchEvent(e);
-    this.onmessage = this.onclose = this.onerror = null;
-    debug('disconnected');
-  }.bind(this), 0);
-};
-
-// See: http://www.erg.abdn.ac.uk/~gerrit/dccp/notes/ccid2/rto_estimator/
-// and RFC 2988.
-SockJS.prototype.countRTO = function(rtt) {
-  // In a local environment, when using IE8/9 and the `jsonp-polling`
-  // transport the time needed to establish a connection (the time that pass
-  // from the opening of the transport to the call of `_dispatchOpen`) is
-  // around 200msec (the lower bound used in the article above) and this
-  // causes spurious timeouts. For this reason we calculate a value slightly
-  // larger than that used in the article.
-  if (rtt > 100) {
-    return 4 * rtt; // rto > 400msec
-  }
-  return 300 + rtt; // 300msec < rto <= 400msec
-};
-
-module.exports = function(availableTransports) {
-  transports = transport(availableTransports);
-  require('./iframe-bootstrap')(SockJS, availableTransports);
-  return SockJS;
-};

+ 0 - 452
node_modules.bak/sockjs-client/lib/shims.js

@@ -1,452 +0,0 @@
-/* eslint-disable */
-/* jscs: disable */
-'use strict';
-
-// pulled specific shims from https://github.com/es-shims/es5-shim
-
-var ArrayPrototype = Array.prototype;
-var ObjectPrototype = Object.prototype;
-var FunctionPrototype = Function.prototype;
-var StringPrototype = String.prototype;
-var array_slice = ArrayPrototype.slice;
-
-var _toString = ObjectPrototype.toString;
-var isFunction = function (val) {
-    return ObjectPrototype.toString.call(val) === '[object Function]';
-};
-var isArray = function isArray(obj) {
-    return _toString.call(obj) === '[object Array]';
-};
-var isString = function isString(obj) {
-    return _toString.call(obj) === '[object String]';
-};
-
-var supportsDescriptors = Object.defineProperty && (function () {
-    try {
-        Object.defineProperty({}, 'x', {});
-        return true;
-    } catch (e) { /* this is ES3 */
-        return false;
-    }
-}());
-
-// Define configurable, writable and non-enumerable props
-// if they don't exist.
-var defineProperty;
-if (supportsDescriptors) {
-    defineProperty = function (object, name, method, forceAssign) {
-        if (!forceAssign && (name in object)) { return; }
-        Object.defineProperty(object, name, {
-            configurable: true,
-            enumerable: false,
-            writable: true,
-            value: method
-        });
-    };
-} else {
-    defineProperty = function (object, name, method, forceAssign) {
-        if (!forceAssign && (name in object)) { return; }
-        object[name] = method;
-    };
-}
-var defineProperties = function (object, map, forceAssign) {
-    for (var name in map) {
-        if (ObjectPrototype.hasOwnProperty.call(map, name)) {
-          defineProperty(object, name, map[name], forceAssign);
-        }
-    }
-};
-
-var toObject = function (o) {
-    if (o == null) { // this matches both null and undefined
-        throw new TypeError("can't convert " + o + ' to object');
-    }
-    return Object(o);
-};
-
-//
-// Util
-// ======
-//
-
-// ES5 9.4
-// http://es5.github.com/#x9.4
-// http://jsperf.com/to-integer
-
-function toInteger(num) {
-    var n = +num;
-    if (n !== n) { // isNaN
-        n = 0;
-    } else if (n !== 0 && n !== (1 / 0) && n !== -(1 / 0)) {
-        n = (n > 0 || -1) * Math.floor(Math.abs(n));
-    }
-    return n;
-}
-
-function ToUint32(x) {
-    return x >>> 0;
-}
-
-//
-// Function
-// ========
-//
-
-// ES-5 15.3.4.5
-// http://es5.github.com/#x15.3.4.5
-
-function Empty() {}
-
-defineProperties(FunctionPrototype, {
-    bind: function bind(that) { // .length is 1
-        // 1. Let Target be the this value.
-        var target = this;
-        // 2. If IsCallable(Target) is false, throw a TypeError exception.
-        if (!isFunction(target)) {
-            throw new TypeError('Function.prototype.bind called on incompatible ' + target);
-        }
-        // 3. Let A be a new (possibly empty) internal list of all of the
-        //   argument values provided after thisArg (arg1, arg2 etc), in order.
-        // XXX slicedArgs will stand in for "A" if used
-        var args = array_slice.call(arguments, 1); // for normal call
-        // 4. Let F be a new native ECMAScript object.
-        // 11. Set the [[Prototype]] internal property of F to the standard
-        //   built-in Function prototype object as specified in 15.3.3.1.
-        // 12. Set the [[Call]] internal property of F as described in
-        //   15.3.4.5.1.
-        // 13. Set the [[Construct]] internal property of F as described in
-        //   15.3.4.5.2.
-        // 14. Set the [[HasInstance]] internal property of F as described in
-        //   15.3.4.5.3.
-        var binder = function () {
-
-            if (this instanceof bound) {
-                // 15.3.4.5.2 [[Construct]]
-                // When the [[Construct]] internal method of a function object,
-                // F that was created using the bind function is called with a
-                // list of arguments ExtraArgs, the following steps are taken:
-                // 1. Let target be the value of F's [[TargetFunction]]
-                //   internal property.
-                // 2. If target has no [[Construct]] internal method, a
-                //   TypeError exception is thrown.
-                // 3. Let boundArgs be the value of F's [[BoundArgs]] internal
-                //   property.
-                // 4. Let args be a new list containing the same values as the
-                //   list boundArgs in the same order followed by the same
-                //   values as the list ExtraArgs in the same order.
-                // 5. Return the result of calling the [[Construct]] internal
-                //   method of target providing args as the arguments.
-
-                var result = target.apply(
-                    this,
-                    args.concat(array_slice.call(arguments))
-                );
-                if (Object(result) === result) {
-                    return result;
-                }
-                return this;
-
-            } else {
-                // 15.3.4.5.1 [[Call]]
-                // When the [[Call]] internal method of a function object, F,
-                // which was created using the bind function is called with a
-                // this value and a list of arguments ExtraArgs, the following
-                // steps are taken:
-                // 1. Let boundArgs be the value of F's [[BoundArgs]] internal
-                //   property.
-                // 2. Let boundThis be the value of F's [[BoundThis]] internal
-                //   property.
-                // 3. Let target be the value of F's [[TargetFunction]] internal
-                //   property.
-                // 4. Let args be a new list containing the same values as the
-                //   list boundArgs in the same order followed by the same
-                //   values as the list ExtraArgs in the same order.
-                // 5. Return the result of calling the [[Call]] internal method
-                //   of target providing boundThis as the this value and
-                //   providing args as the arguments.
-
-                // equiv: target.call(this, ...boundArgs, ...args)
-                return target.apply(
-                    that,
-                    args.concat(array_slice.call(arguments))
-                );
-
-            }
-
-        };
-
-        // 15. If the [[Class]] internal property of Target is "Function", then
-        //     a. Let L be the length property of Target minus the length of A.
-        //     b. Set the length own property of F to either 0 or L, whichever is
-        //       larger.
-        // 16. Else set the length own property of F to 0.
-
-        var boundLength = Math.max(0, target.length - args.length);
-
-        // 17. Set the attributes of the length own property of F to the values
-        //   specified in 15.3.5.1.
-        var boundArgs = [];
-        for (var i = 0; i < boundLength; i++) {
-            boundArgs.push('$' + i);
-        }
-
-        // XXX Build a dynamic function with desired amount of arguments is the only
-        // way to set the length property of a function.
-        // In environments where Content Security Policies enabled (Chrome extensions,
-        // for ex.) all use of eval or Function costructor throws an exception.
-        // However in all of these environments Function.prototype.bind exists
-        // and so this code will never be executed.
-        var bound = Function('binder', 'return function (' + boundArgs.join(',') + '){ return binder.apply(this, arguments); }')(binder);
-
-        if (target.prototype) {
-            Empty.prototype = target.prototype;
-            bound.prototype = new Empty();
-            // Clean up dangling references.
-            Empty.prototype = null;
-        }
-
-        // TODO
-        // 18. Set the [[Extensible]] internal property of F to true.
-
-        // TODO
-        // 19. Let thrower be the [[ThrowTypeError]] function Object (13.2.3).
-        // 20. Call the [[DefineOwnProperty]] internal method of F with
-        //   arguments "caller", PropertyDescriptor {[[Get]]: thrower, [[Set]]:
-        //   thrower, [[Enumerable]]: false, [[Configurable]]: false}, and
-        //   false.
-        // 21. Call the [[DefineOwnProperty]] internal method of F with
-        //   arguments "arguments", PropertyDescriptor {[[Get]]: thrower,
-        //   [[Set]]: thrower, [[Enumerable]]: false, [[Configurable]]: false},
-        //   and false.
-
-        // TODO
-        // NOTE Function objects created using Function.prototype.bind do not
-        // have a prototype property or the [[Code]], [[FormalParameters]], and
-        // [[Scope]] internal properties.
-        // XXX can't delete prototype in pure-js.
-
-        // 22. Return F.
-        return bound;
-    }
-});
-
-//
-// Array
-// =====
-//
-
-// ES5 15.4.3.2
-// http://es5.github.com/#x15.4.3.2
-// https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/isArray
-defineProperties(Array, { isArray: isArray });
-
-
-var boxedString = Object('a');
-var splitString = boxedString[0] !== 'a' || !(0 in boxedString);
-
-var properlyBoxesContext = function properlyBoxed(method) {
-    // Check node 0.6.21 bug where third parameter is not boxed
-    var properlyBoxesNonStrict = true;
-    var properlyBoxesStrict = true;
-    if (method) {
-        method.call('foo', function (_, __, context) {
-            if (typeof context !== 'object') { properlyBoxesNonStrict = false; }
-        });
-
-        method.call([1], function () {
-            'use strict';
-            properlyBoxesStrict = typeof this === 'string';
-        }, 'x');
-    }
-    return !!method && properlyBoxesNonStrict && properlyBoxesStrict;
-};
-
-defineProperties(ArrayPrototype, {
-    forEach: function forEach(fun /*, thisp*/) {
-        var object = toObject(this),
-            self = splitString && isString(this) ? this.split('') : object,
-            thisp = arguments[1],
-            i = -1,
-            length = self.length >>> 0;
-
-        // If no callback function or if callback is not a callable function
-        if (!isFunction(fun)) {
-            throw new TypeError(); // TODO message
-        }
-
-        while (++i < length) {
-            if (i in self) {
-                // Invoke the callback function with call, passing arguments:
-                // context, property value, property key, thisArg object
-                // context
-                fun.call(thisp, self[i], i, object);
-            }
-        }
-    }
-}, !properlyBoxesContext(ArrayPrototype.forEach));
-
-// ES5 15.4.4.14
-// http://es5.github.com/#x15.4.4.14
-// https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Array/indexOf
-var hasFirefox2IndexOfBug = Array.prototype.indexOf && [0, 1].indexOf(1, 2) !== -1;
-defineProperties(ArrayPrototype, {
-    indexOf: function indexOf(sought /*, fromIndex */ ) {
-        var self = splitString && isString(this) ? this.split('') : toObject(this),
-            length = self.length >>> 0;
-
-        if (!length) {
-            return -1;
-        }
-
-        var i = 0;
-        if (arguments.length > 1) {
-            i = toInteger(arguments[1]);
-        }
-
-        // handle negative indices
-        i = i >= 0 ? i : Math.max(0, length + i);
-        for (; i < length; i++) {
-            if (i in self && self[i] === sought) {
-                return i;
-            }
-        }
-        return -1;
-    }
-}, hasFirefox2IndexOfBug);
-
-//
-// String
-// ======
-//
-
-// ES5 15.5.4.14
-// http://es5.github.com/#x15.5.4.14
-
-// [bugfix, IE lt 9, firefox 4, Konqueror, Opera, obscure browsers]
-// Many browsers do not split properly with regular expressions or they
-// do not perform the split correctly under obscure conditions.
-// See http://blog.stevenlevithan.com/archives/cross-browser-split
-// I've tested in many browsers and this seems to cover the deviant ones:
-//    'ab'.split(/(?:ab)*/) should be ["", ""], not [""]
-//    '.'.split(/(.?)(.?)/) should be ["", ".", "", ""], not ["", ""]
-//    'tesst'.split(/(s)*/) should be ["t", undefined, "e", "s", "t"], not
-//       [undefined, "t", undefined, "e", ...]
-//    ''.split(/.?/) should be [], not [""]
-//    '.'.split(/()()/) should be ["."], not ["", "", "."]
-
-var string_split = StringPrototype.split;
-if (
-    'ab'.split(/(?:ab)*/).length !== 2 ||
-    '.'.split(/(.?)(.?)/).length !== 4 ||
-    'tesst'.split(/(s)*/)[1] === 't' ||
-    'test'.split(/(?:)/, -1).length !== 4 ||
-    ''.split(/.?/).length ||
-    '.'.split(/()()/).length > 1
-) {
-    (function () {
-        var compliantExecNpcg = /()??/.exec('')[1] === void 0; // NPCG: nonparticipating capturing group
-
-        StringPrototype.split = function (separator, limit) {
-            var string = this;
-            if (separator === void 0 && limit === 0) {
-                return [];
-            }
-
-            // If `separator` is not a regex, use native split
-            if (_toString.call(separator) !== '[object RegExp]') {
-                return string_split.call(this, separator, limit);
-            }
-
-            var output = [],
-                flags = (separator.ignoreCase ? 'i' : '') +
-                        (separator.multiline  ? 'm' : '') +
-                        (separator.extended   ? 'x' : '') + // Proposed for ES6
-                        (separator.sticky     ? 'y' : ''), // Firefox 3+
-                lastLastIndex = 0,
-                // Make `global` and avoid `lastIndex` issues by working with a copy
-                separator2, match, lastIndex, lastLength;
-            separator = new RegExp(separator.source, flags + 'g');
-            string += ''; // Type-convert
-            if (!compliantExecNpcg) {
-                // Doesn't need flags gy, but they don't hurt
-                separator2 = new RegExp('^' + separator.source + '$(?!\\s)', flags);
-            }
-            /* Values for `limit`, per the spec:
-             * If undefined: 4294967295 // Math.pow(2, 32) - 1
-             * If 0, Infinity, or NaN: 0
-             * If positive number: limit = Math.floor(limit); if (limit > 4294967295) limit -= 4294967296;
-             * If negative number: 4294967296 - Math.floor(Math.abs(limit))
-             * If other: Type-convert, then use the above rules
-             */
-            limit = limit === void 0 ?
-                -1 >>> 0 : // Math.pow(2, 32) - 1
-                ToUint32(limit);
-            while (match = separator.exec(string)) {
-                // `separator.lastIndex` is not reliable cross-browser
-                lastIndex = match.index + match[0].length;
-                if (lastIndex > lastLastIndex) {
-                    output.push(string.slice(lastLastIndex, match.index));
-                    // Fix browsers whose `exec` methods don't consistently return `undefined` for
-                    // nonparticipating capturing groups
-                    if (!compliantExecNpcg && match.length > 1) {
-                        match[0].replace(separator2, function () {
-                            for (var i = 1; i < arguments.length - 2; i++) {
-                                if (arguments[i] === void 0) {
-                                    match[i] = void 0;
-                                }
-                            }
-                        });
-                    }
-                    if (match.length > 1 && match.index < string.length) {
-                        ArrayPrototype.push.apply(output, match.slice(1));
-                    }
-                    lastLength = match[0].length;
-                    lastLastIndex = lastIndex;
-                    if (output.length >= limit) {
-                        break;
-                    }
-                }
-                if (separator.lastIndex === match.index) {
-                    separator.lastIndex++; // Avoid an infinite loop
-                }
-            }
-            if (lastLastIndex === string.length) {
-                if (lastLength || !separator.test('')) {
-                    output.push('');
-                }
-            } else {
-                output.push(string.slice(lastLastIndex));
-            }
-            return output.length > limit ? output.slice(0, limit) : output;
-        };
-    }());
-
-// [bugfix, chrome]
-// If separator is undefined, then the result array contains just one String,
-// which is the this value (converted to a String). If limit is not undefined,
-// then the output array is truncated so that it contains no more than limit
-// elements.
-// "0".split(undefined, 0) -> []
-} else if ('0'.split(void 0, 0).length) {
-    StringPrototype.split = function split(separator, limit) {
-        if (separator === void 0 && limit === 0) { return []; }
-        return string_split.call(this, separator, limit);
-    };
-}
-
-// ECMA-262, 3rd B.2.3
-// Not an ECMAScript standard, although ECMAScript 3rd Edition has a
-// non-normative section suggesting uniform semantics and it should be
-// normalized across all browsers
-// [bugfix, IE lt 9] IE < 9 substr() with negative value not working in IE
-var string_substr = StringPrototype.substr;
-var hasNegativeSubstrBug = ''.substr && '0b'.substr(-1) !== 'b';
-defineProperties(StringPrototype, {
-    substr: function substr(start, length) {
-        return string_substr.call(
-            this,
-            start < 0 ? ((start = this.length + start) < 0 ? 0 : start) : start,
-            length
-        );
-    }
-}, hasNegativeSubstrBug);

+ 0 - 18
node_modules.bak/sockjs-client/lib/transport-list.js

@@ -1,18 +0,0 @@
-'use strict';
-
-module.exports = [
-  // streaming transports
-  require('./transport/websocket')
-, require('./transport/xhr-streaming')
-, require('./transport/xdr-streaming')
-, require('./transport/eventsource')
-, require('./transport/lib/iframe-wrap')(require('./transport/eventsource'))
-
-  // polling transports
-, require('./transport/htmlfile')
-, require('./transport/lib/iframe-wrap')(require('./transport/htmlfile'))
-, require('./transport/xhr-polling')
-, require('./transport/xdr-polling')
-, require('./transport/lib/iframe-wrap')(require('./transport/xhr-polling'))
-, require('./transport/jsonp-polling')
-];

+ 0 - 193
node_modules.bak/sockjs-client/lib/transport/browser/abstract-xhr.js

@@ -1,193 +0,0 @@
-'use strict';
-
-var EventEmitter = require('events').EventEmitter
-  , inherits = require('inherits')
-  , utils = require('../../utils/event')
-  , urlUtils = require('../../utils/url')
-  , XHR = global.XMLHttpRequest
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:browser:xhr');
-}
-
-function AbstractXHRObject(method, url, payload, opts) {
-  debug(method, url);
-  var self = this;
-  EventEmitter.call(this);
-
-  setTimeout(function () {
-    self._start(method, url, payload, opts);
-  }, 0);
-}
-
-inherits(AbstractXHRObject, EventEmitter);
-
-AbstractXHRObject.prototype._start = function(method, url, payload, opts) {
-  var self = this;
-
-  try {
-    this.xhr = new XHR();
-  } catch (x) {
-    // intentionally empty
-  }
-
-  if (!this.xhr) {
-    debug('no xhr');
-    this.emit('finish', 0, 'no xhr support');
-    this._cleanup();
-    return;
-  }
-
-  // several browsers cache POSTs
-  url = urlUtils.addQuery(url, 't=' + (+new Date()));
-
-  // Explorer tends to keep connection open, even after the
-  // tab gets closed: http://bugs.jquery.com/ticket/5280
-  this.unloadRef = utils.unloadAdd(function() {
-    debug('unload cleanup');
-    self._cleanup(true);
-  });
-  try {
-    this.xhr.open(method, url, true);
-    if (this.timeout && 'timeout' in this.xhr) {
-      this.xhr.timeout = this.timeout;
-      this.xhr.ontimeout = function() {
-        debug('xhr timeout');
-        self.emit('finish', 0, '');
-        self._cleanup(false);
-      };
-    }
-  } catch (e) {
-    debug('exception', e);
-    // IE raises an exception on wrong port.
-    this.emit('finish', 0, '');
-    this._cleanup(false);
-    return;
-  }
-
-  if ((!opts || !opts.noCredentials) && AbstractXHRObject.supportsCORS) {
-    debug('withCredentials');
-    // Mozilla docs says https://developer.mozilla.org/en/XMLHttpRequest :
-    // "This never affects same-site requests."
-
-    this.xhr.withCredentials = true;
-  }
-  if (opts && opts.headers) {
-    for (var key in opts.headers) {
-      this.xhr.setRequestHeader(key, opts.headers[key]);
-    }
-  }
-
-  this.xhr.onreadystatechange = function() {
-    if (self.xhr) {
-      var x = self.xhr;
-      var text, status;
-      debug('readyState', x.readyState);
-      switch (x.readyState) {
-      case 3:
-        // IE doesn't like peeking into responseText or status
-        // on Microsoft.XMLHTTP and readystate=3
-        try {
-          status = x.status;
-          text = x.responseText;
-        } catch (e) {
-          // intentionally empty
-        }
-        debug('status', status);
-        // IE returns 1223 for 204: http://bugs.jquery.com/ticket/1450
-        if (status === 1223) {
-          status = 204;
-        }
-
-        // IE does return readystate == 3 for 404 answers.
-        if (status === 200 && text && text.length > 0) {
-          debug('chunk');
-          self.emit('chunk', status, text);
-        }
-        break;
-      case 4:
-        status = x.status;
-        debug('status', status);
-        // IE returns 1223 for 204: http://bugs.jquery.com/ticket/1450
-        if (status === 1223) {
-          status = 204;
-        }
-        // IE returns this for a bad port
-        // http://msdn.microsoft.com/en-us/library/windows/desktop/aa383770(v=vs.85).aspx
-        if (status === 12005 || status === 12029) {
-          status = 0;
-        }
-
-        debug('finish', status, x.responseText);
-        self.emit('finish', status, x.responseText);
-        self._cleanup(false);
-        break;
-      }
-    }
-  };
-
-  try {
-    self.xhr.send(payload);
-  } catch (e) {
-    self.emit('finish', 0, '');
-    self._cleanup(false);
-  }
-};
-
-AbstractXHRObject.prototype._cleanup = function(abort) {
-  debug('cleanup');
-  if (!this.xhr) {
-    return;
-  }
-  this.removeAllListeners();
-  utils.unloadDel(this.unloadRef);
-
-  // IE needs this field to be a function
-  this.xhr.onreadystatechange = function() {};
-  if (this.xhr.ontimeout) {
-    this.xhr.ontimeout = null;
-  }
-
-  if (abort) {
-    try {
-      this.xhr.abort();
-    } catch (x) {
-      // intentionally empty
-    }
-  }
-  this.unloadRef = this.xhr = null;
-};
-
-AbstractXHRObject.prototype.close = function() {
-  debug('close');
-  this._cleanup(true);
-};
-
-AbstractXHRObject.enabled = !!XHR;
-// override XMLHttpRequest for IE6/7
-// obfuscate to avoid firewalls
-var axo = ['Active'].concat('Object').join('X');
-if (!AbstractXHRObject.enabled && (axo in global)) {
-  debug('overriding xmlhttprequest');
-  XHR = function() {
-    try {
-      return new global[axo]('Microsoft.XMLHTTP');
-    } catch (e) {
-      return null;
-    }
-  };
-  AbstractXHRObject.enabled = !!new XHR();
-}
-
-var cors = false;
-try {
-  cors = 'withCredentials' in new XHR();
-} catch (ignored) {
-  // intentionally empty
-}
-
-AbstractXHRObject.supportsCORS = cors;
-
-module.exports = AbstractXHRObject;

+ 0 - 1
node_modules.bak/sockjs-client/lib/transport/browser/eventsource.js

@@ -1 +0,0 @@
-module.exports = global.EventSource;

+ 0 - 10
node_modules.bak/sockjs-client/lib/transport/browser/websocket.js

@@ -1,10 +0,0 @@
-'use strict';
-
-var Driver = global.WebSocket || global.MozWebSocket;
-if (Driver) {
-	module.exports = function WebSocketBrowserDriver(url) {
-		return new Driver(url);
-	};
-} else {
-	module.exports = undefined;
-}

+ 0 - 1
node_modules.bak/sockjs-client/lib/transport/driver/eventsource.js

@@ -1 +0,0 @@
-module.exports = require('eventsource');

+ 0 - 1
node_modules.bak/sockjs-client/lib/transport/driver/websocket.js

@@ -1 +0,0 @@
-module.exports = require('faye-websocket').Client;

+ 0 - 72
node_modules.bak/sockjs-client/lib/transport/driver/xhr.js

@@ -1,72 +0,0 @@
-'use strict';
-
-var EventEmitter = require('events').EventEmitter
-  , inherits = require('inherits')
-  , http = require('http')
-  , https = require('https')
-  , URL = require('url-parse')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:driver:xhr');
-}
-
-function XhrDriver(method, url, payload, opts) {
-  debug(method, url, payload);
-  var self = this;
-  EventEmitter.call(this);
-
-  var parsedUrl = new URL(url);
-  var options = {
-    method: method
-  , hostname: parsedUrl.hostname.replace(/\[|\]/g, '')
-  , port: parsedUrl.port
-  , path: parsedUrl.pathname + (parsedUrl.query || '')
-  , headers: opts && opts.headers
-  , agent: false
-  };
-
-  var protocol = parsedUrl.protocol === 'https:' ? https : http;
-  this.req = protocol.request(options, function(res) {
-    res.setEncoding('utf8');
-    var responseText = '';
-
-    res.on('data', function(chunk) {
-      debug('data', chunk);
-      responseText += chunk;
-      self.emit('chunk', 200, responseText);
-    });
-    res.once('end', function() {
-      debug('end');
-      self.emit('finish', res.statusCode, responseText);
-      self.req = null;
-    });
-  });
-
-  this.req.on('error', function(e) {
-    debug('error', e);
-    self.emit('finish', 0, e.message);
-  });
-
-  if (payload) {
-    this.req.write(payload);
-  }
-  this.req.end();
-}
-
-inherits(XhrDriver, EventEmitter);
-
-XhrDriver.prototype.close = function() {
-  debug('close');
-  this.removeAllListeners();
-  if (this.req) {
-    this.req.abort();
-    this.req = null;
-  }
-};
-
-XhrDriver.enabled = true;
-XhrDriver.supportsCORS = true;
-
-module.exports = XhrDriver;

+ 0 - 27
node_modules.bak/sockjs-client/lib/transport/eventsource.js

@@ -1,27 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , AjaxBasedTransport = require('./lib/ajax-based')
-  , EventSourceReceiver = require('./receiver/eventsource')
-  , XHRCorsObject = require('./sender/xhr-cors')
-  , EventSourceDriver = require('eventsource')
-  ;
-
-function EventSourceTransport(transUrl) {
-  if (!EventSourceTransport.enabled()) {
-    throw new Error('Transport created when disabled');
-  }
-
-  AjaxBasedTransport.call(this, transUrl, '/eventsource', EventSourceReceiver, XHRCorsObject);
-}
-
-inherits(EventSourceTransport, AjaxBasedTransport);
-
-EventSourceTransport.enabled = function() {
-  return !!EventSourceDriver;
-};
-
-EventSourceTransport.transportName = 'eventsource';
-EventSourceTransport.roundTrips = 2;
-
-module.exports = EventSourceTransport;

+ 0 - 25
node_modules.bak/sockjs-client/lib/transport/htmlfile.js

@@ -1,25 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , HtmlfileReceiver = require('./receiver/htmlfile')
-  , XHRLocalObject = require('./sender/xhr-local')
-  , AjaxBasedTransport = require('./lib/ajax-based')
-  ;
-
-function HtmlFileTransport(transUrl) {
-  if (!HtmlfileReceiver.enabled) {
-    throw new Error('Transport created when disabled');
-  }
-  AjaxBasedTransport.call(this, transUrl, '/htmlfile', HtmlfileReceiver, XHRLocalObject);
-}
-
-inherits(HtmlFileTransport, AjaxBasedTransport);
-
-HtmlFileTransport.enabled = function(info) {
-  return HtmlfileReceiver.enabled && info.sameOrigin;
-};
-
-HtmlFileTransport.transportName = 'htmlfile';
-HtmlFileTransport.roundTrips = 2;
-
-module.exports = HtmlFileTransport;

+ 0 - 141
node_modules.bak/sockjs-client/lib/transport/iframe.js

@@ -1,141 +0,0 @@
-'use strict';
-
-// Few cool transports do work only for same-origin. In order to make
-// them work cross-domain we shall use iframe, served from the
-// remote domain. New browsers have capabilities to communicate with
-// cross domain iframe using postMessage(). In IE it was implemented
-// from IE 8+, but of course, IE got some details wrong:
-//    http://msdn.microsoft.com/en-us/library/cc197015(v=VS.85).aspx
-//    http://stevesouders.com/misc/test-postmessage.php
-
-var inherits = require('inherits')
-  , JSON3 = require('json3')
-  , EventEmitter = require('events').EventEmitter
-  , version = require('../version')
-  , urlUtils = require('../utils/url')
-  , iframeUtils = require('../utils/iframe')
-  , eventUtils = require('../utils/event')
-  , random = require('../utils/random')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:transport:iframe');
-}
-
-function IframeTransport(transport, transUrl, baseUrl) {
-  if (!IframeTransport.enabled()) {
-    throw new Error('Transport created when disabled');
-  }
-  EventEmitter.call(this);
-
-  var self = this;
-  this.origin = urlUtils.getOrigin(baseUrl);
-  this.baseUrl = baseUrl;
-  this.transUrl = transUrl;
-  this.transport = transport;
-  this.windowId = random.string(8);
-
-  var iframeUrl = urlUtils.addPath(baseUrl, '/iframe.html') + '#' + this.windowId;
-  debug(transport, transUrl, iframeUrl);
-
-  this.iframeObj = iframeUtils.createIframe(iframeUrl, function(r) {
-    debug('err callback');
-    self.emit('close', 1006, 'Unable to load an iframe (' + r + ')');
-    self.close();
-  });
-
-  this.onmessageCallback = this._message.bind(this);
-  eventUtils.attachEvent('message', this.onmessageCallback);
-}
-
-inherits(IframeTransport, EventEmitter);
-
-IframeTransport.prototype.close = function() {
-  debug('close');
-  this.removeAllListeners();
-  if (this.iframeObj) {
-    eventUtils.detachEvent('message', this.onmessageCallback);
-    try {
-      // When the iframe is not loaded, IE raises an exception
-      // on 'contentWindow'.
-      this.postMessage('c');
-    } catch (x) {
-      // intentionally empty
-    }
-    this.iframeObj.cleanup();
-    this.iframeObj = null;
-    this.onmessageCallback = this.iframeObj = null;
-  }
-};
-
-IframeTransport.prototype._message = function(e) {
-  debug('message', e.data);
-  if (!urlUtils.isOriginEqual(e.origin, this.origin)) {
-    debug('not same origin', e.origin, this.origin);
-    return;
-  }
-
-  var iframeMessage;
-  try {
-    iframeMessage = JSON3.parse(e.data);
-  } catch (ignored) {
-    debug('bad json', e.data);
-    return;
-  }
-
-  if (iframeMessage.windowId !== this.windowId) {
-    debug('mismatched window id', iframeMessage.windowId, this.windowId);
-    return;
-  }
-
-  switch (iframeMessage.type) {
-  case 's':
-    this.iframeObj.loaded();
-    // window global dependency
-    this.postMessage('s', JSON3.stringify([
-      version
-    , this.transport
-    , this.transUrl
-    , this.baseUrl
-    ]));
-    break;
-  case 't':
-    this.emit('message', iframeMessage.data);
-    break;
-  case 'c':
-    var cdata;
-    try {
-      cdata = JSON3.parse(iframeMessage.data);
-    } catch (ignored) {
-      debug('bad json', iframeMessage.data);
-      return;
-    }
-    this.emit('close', cdata[0], cdata[1]);
-    this.close();
-    break;
-  }
-};
-
-IframeTransport.prototype.postMessage = function(type, data) {
-  debug('postMessage', type, data);
-  this.iframeObj.post(JSON3.stringify({
-    windowId: this.windowId
-  , type: type
-  , data: data || ''
-  }), this.origin);
-};
-
-IframeTransport.prototype.send = function(message) {
-  debug('send', message);
-  this.postMessage('m', message);
-};
-
-IframeTransport.enabled = function() {
-  return iframeUtils.iframeEnabled;
-};
-
-IframeTransport.transportName = 'iframe';
-IframeTransport.roundTrips = 2;
-
-module.exports = IframeTransport;

+ 0 - 34
node_modules.bak/sockjs-client/lib/transport/jsonp-polling.js

@@ -1,34 +0,0 @@
-'use strict';
-
-// The simplest and most robust transport, using the well-know cross
-// domain hack - JSONP. This transport is quite inefficient - one
-// message could use up to one http request. But at least it works almost
-// everywhere.
-// Known limitations:
-//   o you will get a spinning cursor
-//   o for Konqueror a dumb timer is needed to detect errors
-
-var inherits = require('inherits')
-  , SenderReceiver = require('./lib/sender-receiver')
-  , JsonpReceiver = require('./receiver/jsonp')
-  , jsonpSender = require('./sender/jsonp')
-  ;
-
-function JsonPTransport(transUrl) {
-  if (!JsonPTransport.enabled()) {
-    throw new Error('Transport created when disabled');
-  }
-  SenderReceiver.call(this, transUrl, '/jsonp', jsonpSender, JsonpReceiver);
-}
-
-inherits(JsonPTransport, SenderReceiver);
-
-JsonPTransport.enabled = function() {
-  return !!global.document;
-};
-
-JsonPTransport.transportName = 'jsonp-polling';
-JsonPTransport.roundTrips = 1;
-JsonPTransport.needBody = true;
-
-module.exports = JsonPTransport;

+ 0 - 49
node_modules.bak/sockjs-client/lib/transport/lib/ajax-based.js

@@ -1,49 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , urlUtils = require('../../utils/url')
-  , SenderReceiver = require('./sender-receiver')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:ajax-based');
-}
-
-function createAjaxSender(AjaxObject) {
-  return function(url, payload, callback) {
-    debug('create ajax sender', url, payload);
-    var opt = {};
-    if (typeof payload === 'string') {
-      opt.headers = {'Content-type': 'text/plain'};
-    }
-    var ajaxUrl = urlUtils.addPath(url, '/xhr_send');
-    var xo = new AjaxObject('POST', ajaxUrl, payload, opt);
-    xo.once('finish', function(status) {
-      debug('finish', status);
-      xo = null;
-
-      if (status !== 200 && status !== 204) {
-        return callback(new Error('http status ' + status));
-      }
-      callback();
-    });
-    return function() {
-      debug('abort');
-      xo.close();
-      xo = null;
-
-      var err = new Error('Aborted');
-      err.code = 1000;
-      callback(err);
-    };
-  };
-}
-
-function AjaxBasedTransport(transUrl, urlSuffix, Receiver, AjaxObject) {
-  SenderReceiver.call(this, transUrl, urlSuffix, createAjaxSender(AjaxObject), Receiver, AjaxObject);
-}
-
-inherits(AjaxBasedTransport, SenderReceiver);
-
-module.exports = AjaxBasedTransport;

+ 0 - 87
node_modules.bak/sockjs-client/lib/transport/lib/buffered-sender.js

@@ -1,87 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , EventEmitter = require('events').EventEmitter
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:buffered-sender');
-}
-
-function BufferedSender(url, sender) {
-  debug(url);
-  EventEmitter.call(this);
-  this.sendBuffer = [];
-  this.sender = sender;
-  this.url = url;
-}
-
-inherits(BufferedSender, EventEmitter);
-
-BufferedSender.prototype.send = function(message) {
-  debug('send', message);
-  this.sendBuffer.push(message);
-  if (!this.sendStop) {
-    this.sendSchedule();
-  }
-};
-
-// For polling transports in a situation when in the message callback,
-// new message is being send. If the sending connection was started
-// before receiving one, it is possible to saturate the network and
-// timeout due to the lack of receiving socket. To avoid that we delay
-// sending messages by some small time, in order to let receiving
-// connection be started beforehand. This is only a halfmeasure and
-// does not fix the big problem, but it does make the tests go more
-// stable on slow networks.
-BufferedSender.prototype.sendScheduleWait = function() {
-  debug('sendScheduleWait');
-  var self = this;
-  var tref;
-  this.sendStop = function() {
-    debug('sendStop');
-    self.sendStop = null;
-    clearTimeout(tref);
-  };
-  tref = setTimeout(function() {
-    debug('timeout');
-    self.sendStop = null;
-    self.sendSchedule();
-  }, 25);
-};
-
-BufferedSender.prototype.sendSchedule = function() {
-  debug('sendSchedule', this.sendBuffer.length);
-  var self = this;
-  if (this.sendBuffer.length > 0) {
-    var payload = '[' + this.sendBuffer.join(',') + ']';
-    this.sendStop = this.sender(this.url, payload, function(err) {
-      self.sendStop = null;
-      if (err) {
-        debug('error', err);
-        self.emit('close', err.code || 1006, 'Sending error: ' + err);
-        self.close();
-      } else {
-        self.sendScheduleWait();
-      }
-    });
-    this.sendBuffer = [];
-  }
-};
-
-BufferedSender.prototype._cleanup = function() {
-  debug('_cleanup');
-  this.removeAllListeners();
-};
-
-BufferedSender.prototype.close = function() {
-  debug('close');
-  this._cleanup();
-  if (this.sendStop) {
-    this.sendStop();
-    this.sendStop = null;
-  }
-};
-
-module.exports = BufferedSender;

+ 0 - 33
node_modules.bak/sockjs-client/lib/transport/lib/iframe-wrap.js

@@ -1,33 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , IframeTransport = require('../iframe')
-  , objectUtils = require('../../utils/object')
-  ;
-
-module.exports = function(transport) {
-
-  function IframeWrapTransport(transUrl, baseUrl) {
-    IframeTransport.call(this, transport.transportName, transUrl, baseUrl);
-  }
-
-  inherits(IframeWrapTransport, IframeTransport);
-
-  IframeWrapTransport.enabled = function(url, info) {
-    if (!global.document) {
-      return false;
-    }
-
-    var iframeInfo = objectUtils.extend({}, info);
-    iframeInfo.sameOrigin = true;
-    return transport.enabled(iframeInfo) && IframeTransport.enabled();
-  };
-
-  IframeWrapTransport.transportName = 'iframe-' + transport.transportName;
-  IframeWrapTransport.needBody = true;
-  IframeWrapTransport.roundTrips = IframeTransport.roundTrips + transport.roundTrips - 1; // html, javascript (2) + transport - no CORS (1)
-
-  IframeWrapTransport.facadeTransport = transport;
-
-  return IframeWrapTransport;
-};

+ 0 - 57
node_modules.bak/sockjs-client/lib/transport/lib/polling.js

@@ -1,57 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , EventEmitter = require('events').EventEmitter
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:polling');
-}
-
-function Polling(Receiver, receiveUrl, AjaxObject) {
-  debug(receiveUrl);
-  EventEmitter.call(this);
-  this.Receiver = Receiver;
-  this.receiveUrl = receiveUrl;
-  this.AjaxObject = AjaxObject;
-  this._scheduleReceiver();
-}
-
-inherits(Polling, EventEmitter);
-
-Polling.prototype._scheduleReceiver = function() {
-  debug('_scheduleReceiver');
-  var self = this;
-  var poll = this.poll = new this.Receiver(this.receiveUrl, this.AjaxObject);
-
-  poll.on('message', function(msg) {
-    debug('message', msg);
-    self.emit('message', msg);
-  });
-
-  poll.once('close', function(code, reason) {
-    debug('close', code, reason, self.pollIsClosing);
-    self.poll = poll = null;
-
-    if (!self.pollIsClosing) {
-      if (reason === 'network') {
-        self._scheduleReceiver();
-      } else {
-        self.emit('close', code || 1006, reason);
-        self.removeAllListeners();
-      }
-    }
-  });
-};
-
-Polling.prototype.abort = function() {
-  debug('abort');
-  this.removeAllListeners();
-  this.pollIsClosing = true;
-  if (this.poll) {
-    this.poll.abort();
-  }
-};
-
-module.exports = Polling;

+ 0 - 45
node_modules.bak/sockjs-client/lib/transport/lib/sender-receiver.js

@@ -1,45 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , urlUtils = require('../../utils/url')
-  , BufferedSender = require('./buffered-sender')
-  , Polling = require('./polling')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:sender-receiver');
-}
-
-function SenderReceiver(transUrl, urlSuffix, senderFunc, Receiver, AjaxObject) {
-  var pollUrl = urlUtils.addPath(transUrl, urlSuffix);
-  debug(pollUrl);
-  var self = this;
-  BufferedSender.call(this, transUrl, senderFunc);
-
-  this.poll = new Polling(Receiver, pollUrl, AjaxObject);
-  this.poll.on('message', function(msg) {
-    debug('poll message', msg);
-    self.emit('message', msg);
-  });
-  this.poll.once('close', function(code, reason) {
-    debug('poll close', code, reason);
-    self.poll = null;
-    self.emit('close', code, reason);
-    self.close();
-  });
-}
-
-inherits(SenderReceiver, BufferedSender);
-
-SenderReceiver.prototype.close = function() {
-  BufferedSender.prototype.close.call(this);
-  debug('close');
-  this.removeAllListeners();
-  if (this.poll) {
-    this.poll.abort();
-    this.poll = null;
-  }
-};
-
-module.exports = SenderReceiver;

+ 0 - 63
node_modules.bak/sockjs-client/lib/transport/receiver/eventsource.js

@@ -1,63 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , EventEmitter = require('events').EventEmitter
-  , EventSourceDriver = require('eventsource')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:receiver:eventsource');
-}
-
-function EventSourceReceiver(url) {
-  debug(url);
-  EventEmitter.call(this);
-
-  var self = this;
-  var es = this.es = new EventSourceDriver(url);
-  es.onmessage = function(e) {
-    debug('message', e.data);
-    self.emit('message', decodeURI(e.data));
-  };
-  es.onerror = function(e) {
-    debug('error', es.readyState, e);
-    // ES on reconnection has readyState = 0 or 1.
-    // on network error it's CLOSED = 2
-    var reason = (es.readyState !== 2 ? 'network' : 'permanent');
-    self._cleanup();
-    self._close(reason);
-  };
-}
-
-inherits(EventSourceReceiver, EventEmitter);
-
-EventSourceReceiver.prototype.abort = function() {
-  debug('abort');
-  this._cleanup();
-  this._close('user');
-};
-
-EventSourceReceiver.prototype._cleanup = function() {
-  debug('cleanup');
-  var es = this.es;
-  if (es) {
-    es.onmessage = es.onerror = null;
-    es.close();
-    this.es = null;
-  }
-};
-
-EventSourceReceiver.prototype._close = function(reason) {
-  debug('close', reason);
-  var self = this;
-  // Safari and chrome < 15 crash if we close window before
-  // waiting for ES cleanup. See:
-  // https://code.google.com/p/chromium/issues/detail?id=89155
-  setTimeout(function() {
-    self.emit('close', null, reason);
-    self.removeAllListeners();
-  }, 200);
-};
-
-module.exports = EventSourceReceiver;

+ 0 - 87
node_modules.bak/sockjs-client/lib/transport/receiver/htmlfile.js

@@ -1,87 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , iframeUtils = require('../../utils/iframe')
-  , urlUtils = require('../../utils/url')
-  , EventEmitter = require('events').EventEmitter
-  , random = require('../../utils/random')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:receiver:htmlfile');
-}
-
-function HtmlfileReceiver(url) {
-  debug(url);
-  EventEmitter.call(this);
-  var self = this;
-  iframeUtils.polluteGlobalNamespace();
-
-  this.id = 'a' + random.string(6);
-  url = urlUtils.addQuery(url, 'c=' + decodeURIComponent(iframeUtils.WPrefix + '.' + this.id));
-
-  debug('using htmlfile', HtmlfileReceiver.htmlfileEnabled);
-  var constructFunc = HtmlfileReceiver.htmlfileEnabled ?
-      iframeUtils.createHtmlfile : iframeUtils.createIframe;
-
-  global[iframeUtils.WPrefix][this.id] = {
-    start: function() {
-      debug('start');
-      self.iframeObj.loaded();
-    }
-  , message: function(data) {
-      debug('message', data);
-      self.emit('message', data);
-    }
-  , stop: function() {
-      debug('stop');
-      self._cleanup();
-      self._close('network');
-    }
-  };
-  this.iframeObj = constructFunc(url, function() {
-    debug('callback');
-    self._cleanup();
-    self._close('permanent');
-  });
-}
-
-inherits(HtmlfileReceiver, EventEmitter);
-
-HtmlfileReceiver.prototype.abort = function() {
-  debug('abort');
-  this._cleanup();
-  this._close('user');
-};
-
-HtmlfileReceiver.prototype._cleanup = function() {
-  debug('_cleanup');
-  if (this.iframeObj) {
-    this.iframeObj.cleanup();
-    this.iframeObj = null;
-  }
-  delete global[iframeUtils.WPrefix][this.id];
-};
-
-HtmlfileReceiver.prototype._close = function(reason) {
-  debug('_close', reason);
-  this.emit('close', null, reason);
-  this.removeAllListeners();
-};
-
-HtmlfileReceiver.htmlfileEnabled = false;
-
-// obfuscate to avoid firewalls
-var axo = ['Active'].concat('Object').join('X');
-if (axo in global) {
-  try {
-    HtmlfileReceiver.htmlfileEnabled = !!new global[axo]('htmlfile');
-  } catch (x) {
-    // intentionally empty
-  }
-}
-
-HtmlfileReceiver.enabled = HtmlfileReceiver.htmlfileEnabled || iframeUtils.iframeEnabled;
-
-module.exports = HtmlfileReceiver;

+ 0 - 183
node_modules.bak/sockjs-client/lib/transport/receiver/jsonp.js

@@ -1,183 +0,0 @@
-'use strict';
-
-var utils = require('../../utils/iframe')
-  , random = require('../../utils/random')
-  , browser = require('../../utils/browser')
-  , urlUtils = require('../../utils/url')
-  , inherits = require('inherits')
-  , EventEmitter = require('events').EventEmitter
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:receiver:jsonp');
-}
-
-function JsonpReceiver(url) {
-  debug(url);
-  var self = this;
-  EventEmitter.call(this);
-
-  utils.polluteGlobalNamespace();
-
-  this.id = 'a' + random.string(6);
-  var urlWithId = urlUtils.addQuery(url, 'c=' + encodeURIComponent(utils.WPrefix + '.' + this.id));
-
-  global[utils.WPrefix][this.id] = this._callback.bind(this);
-  this._createScript(urlWithId);
-
-  // Fallback mostly for Konqueror - stupid timer, 35 seconds shall be plenty.
-  this.timeoutId = setTimeout(function() {
-    debug('timeout');
-    self._abort(new Error('JSONP script loaded abnormally (timeout)'));
-  }, JsonpReceiver.timeout);
-}
-
-inherits(JsonpReceiver, EventEmitter);
-
-JsonpReceiver.prototype.abort = function() {
-  debug('abort');
-  if (global[utils.WPrefix][this.id]) {
-    var err = new Error('JSONP user aborted read');
-    err.code = 1000;
-    this._abort(err);
-  }
-};
-
-JsonpReceiver.timeout = 35000;
-JsonpReceiver.scriptErrorTimeout = 1000;
-
-JsonpReceiver.prototype._callback = function(data) {
-  debug('_callback', data);
-  this._cleanup();
-
-  if (this.aborting) {
-    return;
-  }
-
-  if (data) {
-    debug('message', data);
-    this.emit('message', data);
-  }
-  this.emit('close', null, 'network');
-  this.removeAllListeners();
-};
-
-JsonpReceiver.prototype._abort = function(err) {
-  debug('_abort', err);
-  this._cleanup();
-  this.aborting = true;
-  this.emit('close', err.code, err.message);
-  this.removeAllListeners();
-};
-
-JsonpReceiver.prototype._cleanup = function() {
-  debug('_cleanup');
-  clearTimeout(this.timeoutId);
-  if (this.script2) {
-    this.script2.parentNode.removeChild(this.script2);
-    this.script2 = null;
-  }
-  if (this.script) {
-    var script = this.script;
-    // Unfortunately, you can't really abort script loading of
-    // the script.
-    script.parentNode.removeChild(script);
-    script.onreadystatechange = script.onerror =
-        script.onload = script.onclick = null;
-    this.script = null;
-  }
-  delete global[utils.WPrefix][this.id];
-};
-
-JsonpReceiver.prototype._scriptError = function() {
-  debug('_scriptError');
-  var self = this;
-  if (this.errorTimer) {
-    return;
-  }
-
-  this.errorTimer = setTimeout(function() {
-    if (!self.loadedOkay) {
-      self._abort(new Error('JSONP script loaded abnormally (onerror)'));
-    }
-  }, JsonpReceiver.scriptErrorTimeout);
-};
-
-JsonpReceiver.prototype._createScript = function(url) {
-  debug('_createScript', url);
-  var self = this;
-  var script = this.script = global.document.createElement('script');
-  var script2;  // Opera synchronous load trick.
-
-  script.id = 'a' + random.string(8);
-  script.src = url;
-  script.type = 'text/javascript';
-  script.charset = 'UTF-8';
-  script.onerror = this._scriptError.bind(this);
-  script.onload = function() {
-    debug('onload');
-    self._abort(new Error('JSONP script loaded abnormally (onload)'));
-  };
-
-  // IE9 fires 'error' event after onreadystatechange or before, in random order.
-  // Use loadedOkay to determine if actually errored
-  script.onreadystatechange = function() {
-    debug('onreadystatechange', script.readyState);
-    if (/loaded|closed/.test(script.readyState)) {
-      if (script && script.htmlFor && script.onclick) {
-        self.loadedOkay = true;
-        try {
-          // In IE, actually execute the script.
-          script.onclick();
-        } catch (x) {
-          // intentionally empty
-        }
-      }
-      if (script) {
-        self._abort(new Error('JSONP script loaded abnormally (onreadystatechange)'));
-      }
-    }
-  };
-  // IE: event/htmlFor/onclick trick.
-  // One can't rely on proper order for onreadystatechange. In order to
-  // make sure, set a 'htmlFor' and 'event' properties, so that
-  // script code will be installed as 'onclick' handler for the
-  // script object. Later, onreadystatechange, manually execute this
-  // code. FF and Chrome doesn't work with 'event' and 'htmlFor'
-  // set. For reference see:
-  //   http://jaubourg.net/2010/07/loading-script-as-onclick-handler-of.html
-  // Also, read on that about script ordering:
-  //   http://wiki.whatwg.org/wiki/Dynamic_Script_Execution_Order
-  if (typeof script.async === 'undefined' && global.document.attachEvent) {
-    // According to mozilla docs, in recent browsers script.async defaults
-    // to 'true', so we may use it to detect a good browser:
-    // https://developer.mozilla.org/en/HTML/Element/script
-    if (!browser.isOpera()) {
-      // Naively assume we're in IE
-      try {
-        script.htmlFor = script.id;
-        script.event = 'onclick';
-      } catch (x) {
-        // intentionally empty
-      }
-      script.async = true;
-    } else {
-      // Opera, second sync script hack
-      script2 = this.script2 = global.document.createElement('script');
-      script2.text = "try{var a = document.getElementById('" + script.id + "'); if(a)a.onerror();}catch(x){};";
-      script.async = script2.async = false;
-    }
-  }
-  if (typeof script.async !== 'undefined') {
-    script.async = true;
-  }
-
-  var head = global.document.getElementsByTagName('head')[0];
-  head.insertBefore(script, head.firstChild);
-  if (script2) {
-    head.insertBefore(script2, head.firstChild);
-  }
-};
-
-module.exports = JsonpReceiver;

+ 0 - 70
node_modules.bak/sockjs-client/lib/transport/receiver/xhr.js

@@ -1,70 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , EventEmitter = require('events').EventEmitter
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:receiver:xhr');
-}
-
-function XhrReceiver(url, AjaxObject) {
-  debug(url);
-  EventEmitter.call(this);
-  var self = this;
-
-  this.bufferPosition = 0;
-
-  this.xo = new AjaxObject('POST', url, null);
-  this.xo.on('chunk', this._chunkHandler.bind(this));
-  this.xo.once('finish', function(status, text) {
-    debug('finish', status, text);
-    self._chunkHandler(status, text);
-    self.xo = null;
-    var reason = status === 200 ? 'network' : 'permanent';
-    debug('close', reason);
-    self.emit('close', null, reason);
-    self._cleanup();
-  });
-}
-
-inherits(XhrReceiver, EventEmitter);
-
-XhrReceiver.prototype._chunkHandler = function(status, text) {
-  debug('_chunkHandler', status);
-  if (status !== 200 || !text) {
-    return;
-  }
-
-  for (var idx = -1; ; this.bufferPosition += idx + 1) {
-    var buf = text.slice(this.bufferPosition);
-    idx = buf.indexOf('\n');
-    if (idx === -1) {
-      break;
-    }
-    var msg = buf.slice(0, idx);
-    if (msg) {
-      debug('message', msg);
-      this.emit('message', msg);
-    }
-  }
-};
-
-XhrReceiver.prototype._cleanup = function() {
-  debug('_cleanup');
-  this.removeAllListeners();
-};
-
-XhrReceiver.prototype.abort = function() {
-  debug('abort');
-  if (this.xo) {
-    this.xo.close();
-    debug('close');
-    this.emit('close', null, 'user');
-    this.xo = null;
-  }
-  this._cleanup();
-};
-
-module.exports = XhrReceiver;

+ 0 - 99
node_modules.bak/sockjs-client/lib/transport/sender/jsonp.js

@@ -1,99 +0,0 @@
-'use strict';
-
-var random = require('../../utils/random')
-  , urlUtils = require('../../utils/url')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:sender:jsonp');
-}
-
-var form, area;
-
-function createIframe(id) {
-  debug('createIframe', id);
-  try {
-    // ie6 dynamic iframes with target="" support (thanks Chris Lambacher)
-    return global.document.createElement('<iframe name="' + id + '">');
-  } catch (x) {
-    var iframe = global.document.createElement('iframe');
-    iframe.name = id;
-    return iframe;
-  }
-}
-
-function createForm() {
-  debug('createForm');
-  form = global.document.createElement('form');
-  form.style.display = 'none';
-  form.style.position = 'absolute';
-  form.method = 'POST';
-  form.enctype = 'application/x-www-form-urlencoded';
-  form.acceptCharset = 'UTF-8';
-
-  area = global.document.createElement('textarea');
-  area.name = 'd';
-  form.appendChild(area);
-
-  global.document.body.appendChild(form);
-}
-
-module.exports = function(url, payload, callback) {
-  debug(url, payload);
-  if (!form) {
-    createForm();
-  }
-  var id = 'a' + random.string(8);
-  form.target = id;
-  form.action = urlUtils.addQuery(urlUtils.addPath(url, '/jsonp_send'), 'i=' + id);
-
-  var iframe = createIframe(id);
-  iframe.id = id;
-  iframe.style.display = 'none';
-  form.appendChild(iframe);
-
-  try {
-    area.value = payload;
-  } catch (e) {
-    // seriously broken browsers get here
-  }
-  form.submit();
-
-  var completed = function(err) {
-    debug('completed', id, err);
-    if (!iframe.onerror) {
-      return;
-    }
-    iframe.onreadystatechange = iframe.onerror = iframe.onload = null;
-    // Opera mini doesn't like if we GC iframe
-    // immediately, thus this timeout.
-    setTimeout(function() {
-      debug('cleaning up', id);
-      iframe.parentNode.removeChild(iframe);
-      iframe = null;
-    }, 500);
-    area.value = '';
-    // It is not possible to detect if the iframe succeeded or
-    // failed to submit our form.
-    callback(err);
-  };
-  iframe.onerror = function() {
-    debug('onerror', id);
-    completed();
-  };
-  iframe.onload = function() {
-    debug('onload', id);
-    completed();
-  };
-  iframe.onreadystatechange = function(e) {
-    debug('onreadystatechange', id, iframe.readyState, e);
-    if (iframe.readyState === 'complete') {
-      completed();
-    }
-  };
-  return function() {
-    debug('aborted', id);
-    completed(new Error('Aborted'));
-  };
-};

+ 0 - 103
node_modules.bak/sockjs-client/lib/transport/sender/xdr.js

@@ -1,103 +0,0 @@
-'use strict';
-
-var EventEmitter = require('events').EventEmitter
-  , inherits = require('inherits')
-  , eventUtils = require('../../utils/event')
-  , browser = require('../../utils/browser')
-  , urlUtils = require('../../utils/url')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:sender:xdr');
-}
-
-// References:
-//   http://ajaxian.com/archives/100-line-ajax-wrapper
-//   http://msdn.microsoft.com/en-us/library/cc288060(v=VS.85).aspx
-
-function XDRObject(method, url, payload) {
-  debug(method, url);
-  var self = this;
-  EventEmitter.call(this);
-
-  setTimeout(function() {
-    self._start(method, url, payload);
-  }, 0);
-}
-
-inherits(XDRObject, EventEmitter);
-
-XDRObject.prototype._start = function(method, url, payload) {
-  debug('_start');
-  var self = this;
-  var xdr = new global.XDomainRequest();
-  // IE caches even POSTs
-  url = urlUtils.addQuery(url, 't=' + (+new Date()));
-
-  xdr.onerror = function() {
-    debug('onerror');
-    self._error();
-  };
-  xdr.ontimeout = function() {
-    debug('ontimeout');
-    self._error();
-  };
-  xdr.onprogress = function() {
-    debug('progress', xdr.responseText);
-    self.emit('chunk', 200, xdr.responseText);
-  };
-  xdr.onload = function() {
-    debug('load');
-    self.emit('finish', 200, xdr.responseText);
-    self._cleanup(false);
-  };
-  this.xdr = xdr;
-  this.unloadRef = eventUtils.unloadAdd(function() {
-    self._cleanup(true);
-  });
-  try {
-    // Fails with AccessDenied if port number is bogus
-    this.xdr.open(method, url);
-    if (this.timeout) {
-      this.xdr.timeout = this.timeout;
-    }
-    this.xdr.send(payload);
-  } catch (x) {
-    this._error();
-  }
-};
-
-XDRObject.prototype._error = function() {
-  this.emit('finish', 0, '');
-  this._cleanup(false);
-};
-
-XDRObject.prototype._cleanup = function(abort) {
-  debug('cleanup', abort);
-  if (!this.xdr) {
-    return;
-  }
-  this.removeAllListeners();
-  eventUtils.unloadDel(this.unloadRef);
-
-  this.xdr.ontimeout = this.xdr.onerror = this.xdr.onprogress = this.xdr.onload = null;
-  if (abort) {
-    try {
-      this.xdr.abort();
-    } catch (x) {
-      // intentionally empty
-    }
-  }
-  this.unloadRef = this.xdr = null;
-};
-
-XDRObject.prototype.close = function() {
-  debug('close');
-  this._cleanup(true);
-};
-
-// IE 8/9 if the request target uses the same scheme - #79
-XDRObject.enabled = !!(global.XDomainRequest && browser.hasDomain());
-
-module.exports = XDRObject;

+ 0 - 15
node_modules.bak/sockjs-client/lib/transport/sender/xhr-cors.js

@@ -1,15 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , XhrDriver = require('../driver/xhr')
-  ;
-
-function XHRCorsObject(method, url, payload, opts) {
-  XhrDriver.call(this, method, url, payload, opts);
-}
-
-inherits(XHRCorsObject, XhrDriver);
-
-XHRCorsObject.enabled = XhrDriver.enabled && XhrDriver.supportsCORS;
-
-module.exports = XHRCorsObject;

+ 0 - 24
node_modules.bak/sockjs-client/lib/transport/sender/xhr-fake.js

@@ -1,24 +0,0 @@
-'use strict';
-
-var EventEmitter = require('events').EventEmitter
-  , inherits = require('inherits')
-  ;
-
-function XHRFake(/* method, url, payload, opts */) {
-  var self = this;
-  EventEmitter.call(this);
-
-  this.to = setTimeout(function() {
-    self.emit('finish', 200, '{}');
-  }, XHRFake.timeout);
-}
-
-inherits(XHRFake, EventEmitter);
-
-XHRFake.prototype.close = function() {
-  clearTimeout(this.to);
-};
-
-XHRFake.timeout = 2000;
-
-module.exports = XHRFake;

+ 0 - 17
node_modules.bak/sockjs-client/lib/transport/sender/xhr-local.js

@@ -1,17 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , XhrDriver = require('../driver/xhr')
-  ;
-
-function XHRLocalObject(method, url, payload /*, opts */) {
-  XhrDriver.call(this, method, url, payload, {
-    noCredentials: true
-  });
-}
-
-inherits(XHRLocalObject, XhrDriver);
-
-XHRLocalObject.enabled = XhrDriver.enabled;
-
-module.exports = XHRLocalObject;

+ 0 - 99
node_modules.bak/sockjs-client/lib/transport/websocket.js

@@ -1,99 +0,0 @@
-'use strict';
-
-var utils = require('../utils/event')
-  , urlUtils = require('../utils/url')
-  , inherits = require('inherits')
-  , EventEmitter = require('events').EventEmitter
-  , WebsocketDriver = require('./driver/websocket')
-  ;
-
-var debug = function() {};
-if (process.env.NODE_ENV !== 'production') {
-  debug = require('debug')('sockjs-client:websocket');
-}
-
-function WebSocketTransport(transUrl, ignore, options) {
-  if (!WebSocketTransport.enabled()) {
-    throw new Error('Transport created when disabled');
-  }
-
-  EventEmitter.call(this);
-  debug('constructor', transUrl);
-
-  var self = this;
-  var url = urlUtils.addPath(transUrl, '/websocket');
-  if (url.slice(0, 5) === 'https') {
-    url = 'wss' + url.slice(5);
-  } else {
-    url = 'ws' + url.slice(4);
-  }
-  this.url = url;
-
-  this.ws = new WebsocketDriver(this.url, [], options);
-  this.ws.onmessage = function(e) {
-    debug('message event', e.data);
-    self.emit('message', e.data);
-  };
-  // Firefox has an interesting bug. If a websocket connection is
-  // created after onunload, it stays alive even when user
-  // navigates away from the page. In such situation let's lie -
-  // let's not open the ws connection at all. See:
-  // https://github.com/sockjs/sockjs-client/issues/28
-  // https://bugzilla.mozilla.org/show_bug.cgi?id=696085
-  this.unloadRef = utils.unloadAdd(function() {
-    debug('unload');
-    self.ws.close();
-  });
-  this.ws.onclose = function(e) {
-    debug('close event', e.code, e.reason);
-    self.emit('close', e.code, e.reason);
-    self._cleanup();
-  };
-  this.ws.onerror = function(e) {
-    debug('error event', e);
-    self.emit('close', 1006, 'WebSocket connection broken');
-    self._cleanup();
-  };
-}
-
-inherits(WebSocketTransport, EventEmitter);
-
-WebSocketTransport.prototype.send = function(data) {
-  var msg = '[' + data + ']';
-  debug('send', msg);
-  this.ws.send(msg);
-};
-
-WebSocketTransport.prototype.close = function() {
-  debug('close');
-  var ws = this.ws;
-  this._cleanup();
-  if (ws) {
-    ws.close();
-  }
-};
-
-WebSocketTransport.prototype._cleanup = function() {
-  debug('_cleanup');
-  var ws = this.ws;
-  if (ws) {
-    ws.onmessage = ws.onclose = ws.onerror = null;
-  }
-  utils.unloadDel(this.unloadRef);
-  this.unloadRef = this.ws = null;
-  this.removeAllListeners();
-};
-
-WebSocketTransport.enabled = function() {
-  debug('enabled');
-  return !!WebsocketDriver;
-};
-WebSocketTransport.transportName = 'websocket';
-
-// In theory, ws should require 1 round trip. But in chrome, this is
-// not very stable over SSL. Most likely a ws connection requires a
-// separate SSL connection, in which case 2 round trips are an
-// absolute minumum.
-WebSocketTransport.roundTrips = 2;
-
-module.exports = WebSocketTransport;

+ 0 - 23
node_modules.bak/sockjs-client/lib/transport/xdr-polling.js

@@ -1,23 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , AjaxBasedTransport = require('./lib/ajax-based')
-  , XdrStreamingTransport = require('./xdr-streaming')
-  , XhrReceiver = require('./receiver/xhr')
-  , XDRObject = require('./sender/xdr')
-  ;
-
-function XdrPollingTransport(transUrl) {
-  if (!XDRObject.enabled) {
-    throw new Error('Transport created when disabled');
-  }
-  AjaxBasedTransport.call(this, transUrl, '/xhr', XhrReceiver, XDRObject);
-}
-
-inherits(XdrPollingTransport, AjaxBasedTransport);
-
-XdrPollingTransport.enabled = XdrStreamingTransport.enabled;
-XdrPollingTransport.transportName = 'xdr-polling';
-XdrPollingTransport.roundTrips = 2; // preflight, ajax
-
-module.exports = XdrPollingTransport;

+ 0 - 32
node_modules.bak/sockjs-client/lib/transport/xdr-streaming.js

@@ -1,32 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , AjaxBasedTransport = require('./lib/ajax-based')
-  , XhrReceiver = require('./receiver/xhr')
-  , XDRObject = require('./sender/xdr')
-  ;
-
-// According to:
-//   http://stackoverflow.com/questions/1641507/detect-browser-support-for-cross-domain-xmlhttprequests
-//   http://hacks.mozilla.org/2009/07/cross-site-xmlhttprequest-with-cors/
-
-function XdrStreamingTransport(transUrl) {
-  if (!XDRObject.enabled) {
-    throw new Error('Transport created when disabled');
-  }
-  AjaxBasedTransport.call(this, transUrl, '/xhr_streaming', XhrReceiver, XDRObject);
-}
-
-inherits(XdrStreamingTransport, AjaxBasedTransport);
-
-XdrStreamingTransport.enabled = function(info) {
-  if (info.cookie_needed || info.nullOrigin) {
-    return false;
-  }
-  return XDRObject.enabled && info.sameScheme;
-};
-
-XdrStreamingTransport.transportName = 'xdr-streaming';
-XdrStreamingTransport.roundTrips = 2; // preflight, ajax
-
-module.exports = XdrStreamingTransport;

+ 0 - 33
node_modules.bak/sockjs-client/lib/transport/xhr-polling.js

@@ -1,33 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , AjaxBasedTransport = require('./lib/ajax-based')
-  , XhrReceiver = require('./receiver/xhr')
-  , XHRCorsObject = require('./sender/xhr-cors')
-  , XHRLocalObject = require('./sender/xhr-local')
-  ;
-
-function XhrPollingTransport(transUrl) {
-  if (!XHRLocalObject.enabled && !XHRCorsObject.enabled) {
-    throw new Error('Transport created when disabled');
-  }
-  AjaxBasedTransport.call(this, transUrl, '/xhr', XhrReceiver, XHRCorsObject);
-}
-
-inherits(XhrPollingTransport, AjaxBasedTransport);
-
-XhrPollingTransport.enabled = function(info) {
-  if (info.nullOrigin) {
-    return false;
-  }
-
-  if (XHRLocalObject.enabled && info.sameOrigin) {
-    return true;
-  }
-  return XHRCorsObject.enabled;
-};
-
-XhrPollingTransport.transportName = 'xhr-polling';
-XhrPollingTransport.roundTrips = 2; // preflight, ajax
-
-module.exports = XhrPollingTransport;

+ 0 - 41
node_modules.bak/sockjs-client/lib/transport/xhr-streaming.js

@@ -1,41 +0,0 @@
-'use strict';
-
-var inherits = require('inherits')
-  , AjaxBasedTransport = require('./lib/ajax-based')
-  , XhrReceiver = require('./receiver/xhr')
-  , XHRCorsObject = require('./sender/xhr-cors')
-  , XHRLocalObject = require('./sender/xhr-local')
-  , browser = require('../utils/browser')
-  ;
-
-function XhrStreamingTransport(transUrl) {
-  if (!XHRLocalObject.enabled && !XHRCorsObject.enabled) {
-    throw new Error('Transport created when disabled');
-  }
-  AjaxBasedTransport.call(this, transUrl, '/xhr_streaming', XhrReceiver, XHRCorsObject);
-}
-
-inherits(XhrStreamingTransport, AjaxBasedTransport);
-
-XhrStreamingTransport.enabled = function(info) {
-  if (info.nullOrigin) {
-    return false;
-  }
-  // Opera doesn't support xhr-streaming #60
-  // But it might be able to #92
-  if (browser.isOpera()) {
-    return false;
-  }
-
-  return XHRCorsObject.enabled;
-};
-
-XhrStreamingTransport.transportName = 'xhr-streaming';
-XhrStreamingTransport.roundTrips = 2; // preflight, ajax
-
-// Safari gets confused when a streaming ajax request is started
-// before onload. This causes the load indicator to spin indefinetely.
-// Only require body when used in a browser
-XhrStreamingTransport.needBody = !!global.document;
-
-module.exports = XhrStreamingTransport;

+ 0 - 17
node_modules.bak/sockjs-client/lib/utils/browser-crypto.js

@@ -1,17 +0,0 @@
-'use strict';
-
-if (global.crypto && global.crypto.getRandomValues) {
-  module.exports.randomBytes = function(length) {
-    var bytes = new Uint8Array(length);
-    global.crypto.getRandomValues(bytes);
-    return bytes;
-  };
-} else {
-  module.exports.randomBytes = function(length) {
-    var bytes = new Array(length);
-    for (var i = 0; i < length; i++) {
-      bytes[i] = Math.floor(Math.random() * 256);
-    }
-    return bytes;
-  };
-}

+ 0 - 27
node_modules.bak/sockjs-client/lib/utils/browser.js

@@ -1,27 +0,0 @@
-'use strict';
-
-module.exports = {
-  isOpera: function() {
-    return global.navigator &&
-      /opera/i.test(global.navigator.userAgent);
-  }
-
-, isKonqueror: function() {
-    return global.navigator &&
-      /konqueror/i.test(global.navigator.userAgent);
-  }
-
-  // #187 wrap document.domain in try/catch because of WP8 from file:///
-, hasDomain: function () {
-    // non-browser client always has a domain
-    if (!global.document) {
-      return true;
-    }
-
-    try {
-      return !!global.document.domain;
-    } catch (e) {
-      return false;
-    }
-  }
-};

+ 0 - 0
node_modules.bak/sockjs-client/lib/utils/escape.js


部分文件因为文件数量过多而无法显示