Remove error code

This commit is contained in:
RMidhunSuresh 2022-02-04 16:37:43 +05:30
parent 891375a885
commit e8c480426a
2 changed files with 1 additions and 11 deletions

View file

@ -101,10 +101,6 @@ export class Registration {
else {
throw new Error("This stage could not be completed!");
}
case 400:
default:
const error = "error" in response? response.error: "Could not parse response";
throw new Error(error);
}
}

View file

@ -21,7 +21,7 @@ export type AccountDetails = {
inhibitLogin: boolean;
}
export type RegistrationResponse = RegistrationResponseMoreDataNeeded | RegistrationResponseError | RegistrationResponseSuccess;
export type RegistrationResponse = RegistrationResponseMoreDataNeeded | RegistrationResponseSuccess;
export type RegistrationResponseMoreDataNeeded = {
completed?: string[];
@ -31,12 +31,6 @@ export type RegistrationResponseMoreDataNeeded = {
status: 401;
}
type RegistrationResponseError = {
errcode: string;
error: string;
status: 400;
}
export type RegistrationResponseSuccess = {
user_id: string;
device_id: string;