Added register method for client