Add 'Remove' and 'Modify' function, code cleanup