fix active customer detection