Fix problem with old Node

This commit is contained in:
Cheng Zhao 2016-04-07 15:56:25 +09:00
parent 71b67534a8
commit cb47dfa90e

View file

@ -1 +1,6 @@
var os = require('os')
if (os.endianness) {
console.log(require('os').endianness() === 'BE' ? 'big' : 'little') console.log(require('os').endianness() === 'BE' ? 'big' : 'little')
} else { // Your Node is rather old, but I don't care.
console.log('little')
}