function GetMostRecentFileName(dir) {
	var files = fs.readdirSync(dir);

	const filtered = _.filter(files, (f) => {
		let fullpath = path.join(dir, f);
		return path.extname(fullpath) === ".json";
	});

	// use underscore for max()
	return _.max(filtered, function (f) {
		var fullpath = path.join(CONFIG.GUESS_PATH, f);
		return fs.statSync(fullpath).ctime;
	});
}
// Return only base file name without dir
Return only base file name without dir
Return only base file name without dir
function GetMostRecentFileName(dir) {
	var files = fs.readdirSync(dir);
	const filtered = _.filter(files, (f) => {
		let fullpath = path.join(dir, f);
		return path.extname(fullpath) === ".json";
	});
	return _.max(filtered, function (f) {
		var fullpath = path.join(CONFIG.GUESS_PATH, f);
		return fs.statSync(fullpath).ctime;
	});
}
function GetMostRecentFileName ( dir ) { var files = fs . readdirSync ( dir ) ; const filtered = _ . filter ( files , ( f ) => { let fullpath = path . join ( dir , f ) ; return path . extname ( fullpath ) === ".json" ; } ) ; return _ . max ( filtered , function ( f ) { var fullpath = path . join ( CONFIG . GUESS_PATH , f ) ; return fs . statSync ( fullpath ) . ctime ; } ) ; }
Return only base file name without dir
Return only base file name without dir
// use underscore for max()