tasks/aws_s3.js
function (key, dest) {

			var path;

			if (_.last(dest) === '/') {
				// if the path string is a directory, remove it from the key
				path = key.replace(dest, '');
			}
			else if (key.replace(dest, '') === '') {
				path = _.last(key.split('/'));
			}
			else {
				path = key;
			}

			return path;
		}
function (key, dest) {

			var path;

			if (_.last(dest) === '/') {
				// if the path string is a directory, remove it from the key
				path = key.replace(dest, '');
			}
			else if (key.replace(dest, '') === '') {
				path = _.last(key.split('/'));
			}
			else {
				path = key;
			}

			return path;
		}
function ( key , dest ) { var path ; if ( _ . last ( dest ) === '/' ) { // if the path string is a directory, remove it from the key path = key . replace ( dest , '' ) ; } else if ( key . replace ( dest , '' ) === '' ) { path = _ . last ( key . split ( '/' ) ) ; } else { path = key ; } return path ; }
Get the key URL relative to a path string
Get the key URL relative to a path string