Fix the undo operation on delete operations not working. Fixes #175.