Minor simplifications
Fixed a bug in delete which wasn't climbing high enough up the DOM to remove the item.  Now it searches for the right level to delete at to be a bit more robust.