code: function isFileOrDir(filePath) {
  	let fsStat;
  	try {
  		fsStat = fs.statSync(filePath);
  	} catch (error) {
  		return error;
  	}
  
  	let r = 'file';
  	if (fsStat.isDirectory()) {
  		r = 'directory';
  	}
  
  	return r;
  }
docs: Check if a path points to a file or a directory
  @param  {String} filePath - Path to a file or directory
  @return {String} 'directory' if paths points a directory, 'file' if path points to a file