lib/loader.js
function(fn, suffix) {
	if(suffix.charAt(0) !== '.') {
		suffix = '.' + suffix;
	}
	
	if(fn.length <= suffix.length) {
		return false;
	}
	
	var str = fn.substring(fn.length - suffix.length).toLowerCase();
	suffix = suffix.toLowerCase();
	return str === suffix;
}
function(fn, suffix) {
	if(suffix.charAt(0) !== '.') {
		suffix = '.' + suffix;
	}
	
	if(fn.length <= suffix.length) {
		return false;
	}
	
	var str = fn.substring(fn.length - suffix.length).toLowerCase();
	suffix = suffix.toLowerCase();
	return str === suffix;
}
function ( fn , suffix ) { if ( suffix . charAt ( 0 ) !== '.' ) { suffix = '.' + suffix ; } if ( fn . length <= suffix . length ) { return false ; } var str = fn . substring ( fn . length - suffix . length ) . toLowerCase ( ) ; suffix = suffix . toLowerCase ( ) ; return str === suffix ; }
Check file suffix

@param fn {String} file name
@param suffix {String} suffix string, such as .js, etc.
Check file suffix