Added new functions, detach, remove, first and last