update the remove dirty logic....