(uint8)
| 114159 | return output.join(""); |
| 114160 | } |
| 114161 | function fromByteArray(uint8) { |
| 114162 | var tmp; |
| 114163 | var len3 = uint8.length; |
| 114164 | var extraBytes = len3 % 3 // if we have 1 byte left, pad 2 bytes |
| 114165 | ; |
| 114166 | var parts = []; |
| 114167 | var maxChunkLength = 16383 // must be multiple of 3 |
| 114168 | ; |
| 114169 | // go through the array every three bytes, we'll deal with trailing stuff later |
| 114170 | for(var i3 = 0, len2 = len3 - extraBytes; i3 < len2; i3 += maxChunkLength)parts.push(encodeChunk(uint8, i3, i3 + maxChunkLength > len2 ? len2 : i3 + maxChunkLength)); |
| 114171 | // pad the end with zeros, but make sure to not forget the extra bytes |
| 114172 | if (extraBytes === 1) { |
| 114173 | tmp = uint8[len3 - 1]; |
| 114174 | parts.push(lookup[tmp >> 2] + lookup[tmp << 4 & 0x3F] + "=="); |
| 114175 | } else if (extraBytes === 2) { |
| 114176 | tmp = (uint8[len3 - 2] << 8) + uint8[len3 - 1]; |
| 114177 | parts.push(lookup[tmp >> 10] + lookup[tmp >> 4 & 0x3F] + lookup[tmp << 2 & 0x3F] + "="); |
| 114178 | } |
| 114179 | return parts.join(""); |
| 114180 | } |
| 114181 | |
| 114182 | },{}],"2wWVg":[function(require,module,exports) { |
| 114183 | /*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */ exports.read = function(buffer, offset, isLE, mLen, nBytes) { |
nothing calls this directly
no test coverage detected