node-base64 icon indicating copy to clipboard operation
node-base64 copied to clipboard

Incorrect decoding - weird â characters

Open aslakhellesoy opened this issue 15 years ago • 0 comments

If you try to decode message.base64 in https://gist.github.com/763844 you get slightly wrong output. For example, "It’s ghetto" is part of the decoded string, but it should be "It’s ghetto".

var encoded = require('fs').readFileSync(__dirname + '/message.base64', 'ascii');
console.log(require('base64').decode(encoded));

aslakhellesoy avatar Jan 03 '11 20:01 aslakhellesoy