Merge pull request #803 from hckr/atob-btoa

[FIX] Error with new in btoa
This commit is contained in:
Angelos Chalaris
2018-10-04 16:44:55 +03:00
committed by GitHub
2 changed files with 2 additions and 2 deletions

View File

@ -5,7 +5,7 @@ Creates a base-64 encoded ASCII string from a String object in which each charac
Create a `Buffer` for the given string with binary encoding and use `Buffer.toString('base64')` to return the encoded string.
```js
const btoa = str => new Buffer.from(str, 'binary').toString('base64');
const btoa = str => Buffer.from(str, 'binary').toString('base64');
```
```js