Fix rules engine usage