added - scan function for testing
added - functionality to exports.scan() to pass unit tests