modules/orionode/lib/accessRights.js
function removeWorkspaceAccess(userAccessRights, workspaceId) {
	var newAccessRights = [];
	if(Array.isArray(userAccessRights)) {
		userAccessRights.forEach(function(accessRight) {
			if(!new RegExp("/" + workspaceId + "(\/|$)").test(accessRight.Uri)) {
				newAccessRights.push(accessRight);
			}
		});
	}
	return newAccessRights;
}
function removeWorkspaceAccess(userAccessRights, workspaceId) {
	var newAccessRights = [];
	if(Array.isArray(userAccessRights)) {
		userAccessRights.forEach(function(accessRight) {
			if(!new RegExp("/" + workspaceId + "(\/|$)").test(accessRight.Uri)) {
				newAccessRights.push(accessRight);
			}
		});
	}
	return newAccessRights;
}
function removeWorkspaceAccess ( userAccessRights , workspaceId ) { var newAccessRights = [ ] ; if ( Array . isArray ( userAccessRights ) ) { userAccessRights . forEach ( function ( accessRight ) { if ( ! new RegExp ( "/" + workspaceId + "(\/|$)" ) . test ( accessRight . Uri ) ) { newAccessRights . push ( accessRight ) ; } } ) ; } return newAccessRights ; }
Remove the workspace access for the given workspace ID
@param {{?}[]} userAccessRights The current array of access rights
@param {string} workspaceId The ID of the workspace to remove access for
@returns {{?}[]} The new array of access rights
Remove the workspace access for the given workspace ID