Correct deleting button behaviour