Improve performance of delete
Improved performance of add
Merged with most recent version