(text, encoding)
| 76 | } |
| 77 | |
| 78 | function allocBufferFromStringDeprecated(text, encoding) { |
| 79 | if (typeof text !== 'string') { |
| 80 | throw new TypeError('Expected string, obtained ' + util.inspect(text)); |
| 81 | } |
| 82 | // eslint-disable-next-line |
| 83 | return new Buffer(text, encoding); |
| 84 | } |
| 85 | |
| 86 | function allocBufferFromArrayDeprecated(arr) { |
| 87 | if (!Array.isArray(arr)) { |