Code cleanup for reliable delivery.