refactored read_file_async.js