Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const readFile = require('fs').readFile
- const log = console.log
- module.exports = (fileName, cb) => {
- readFile(fileName, 'utf8', (err, userName) => {
- if (err) return cb(err)
- log(`Hi, ${userName}!`)
- cb(null)
- })
- }
Add Comment
Please, Sign In to add comment