update RegisterAcitivity for handling JSON response