FM/SB: Updated registerUser API to be used for login also