CLeaned up the rules migration script a bit