lib/require.js
function(url) {
			var index = url ? url.lastIndexOf('/') : -1;
			return index == -1 ? url : url.substring(0, index + 1);
		}
function(url) {
			var index = url ? url.lastIndexOf('/') : -1;
			return index == -1 ? url : url.substring(0, index + 1);
		}
function ( url ) { var index = url ? url . lastIndexOf ( '/' ) : - 1 ; return index == - 1 ? url : url . substring ( 0 , index + 1 ) ; }
Remove the filename from a url, if possible, returning the url describing only the parent 'path'.
Remove the filename from a url if possible returning the url describing only the parent path .