fix registry issue