Bug fix - ack the messages if there was an exception