Fix rules errors