delete rules correctly