converted readFile example to ES5