mirror of
https://github.com/bitwarden/browser
synced 2025-12-15 15:53:27 +00:00
[PM-5548] Eliminate in-app purchase logic (#7433)
* Eliminate in-app purchase logic * Remove more in-app logic found, for payment and subscription management --------- Co-authored-by: Lotus Scott <148992878+lscottbw@users.noreply.github.com>
This commit is contained in:
@@ -90,7 +90,6 @@ import { TaxInfoResponse } from "../billing/models/response/tax-info.response";
|
||||
import { TaxRateResponse } from "../billing/models/response/tax-rate.response";
|
||||
import { DeleteRecoverRequest } from "../models/request/delete-recover.request";
|
||||
import { EventRequest } from "../models/request/event.request";
|
||||
import { IapCheckRequest } from "../models/request/iap-check.request";
|
||||
import { KdfRequest } from "../models/request/kdf.request";
|
||||
import { KeysRequest } from "../models/request/keys.request";
|
||||
import { OrganizationImportRequest } from "../models/request/organization-import.request";
|
||||
@@ -169,7 +168,6 @@ export abstract class ApiService {
|
||||
postPasswordHint: (request: PasswordHintRequest) => Promise<any>;
|
||||
postRegister: (request: RegisterRequest) => Promise<RegisterResponse>;
|
||||
postPremium: (data: FormData) => Promise<PaymentResponse>;
|
||||
postIapCheck: (request: IapCheckRequest) => Promise<any>;
|
||||
postReinstatePremium: () => Promise<any>;
|
||||
postCancelPremium: () => Promise<any>;
|
||||
postAccountStorage: (request: StorageRequest) => Promise<PaymentResponse>;
|
||||
|
||||
@@ -5,7 +5,5 @@ export enum PaymentMethodType {
|
||||
BitPay = 3,
|
||||
Credit = 4,
|
||||
WireTransfer = 5,
|
||||
AppleInApp = 6,
|
||||
GoogleInApp = 7,
|
||||
Check = 8,
|
||||
}
|
||||
|
||||
@@ -8,7 +8,6 @@ export class SubscriptionResponse extends BaseResponse {
|
||||
upcomingInvoice: BillingSubscriptionUpcomingInvoiceResponse;
|
||||
license: any;
|
||||
expiration: string;
|
||||
usingInAppPurchase: boolean;
|
||||
|
||||
constructor(response: any) {
|
||||
super(response);
|
||||
@@ -17,7 +16,6 @@ export class SubscriptionResponse extends BaseResponse {
|
||||
this.maxStorageGb = this.getResponseProperty("MaxStorageGb");
|
||||
this.license = this.getResponseProperty("License");
|
||||
this.expiration = this.getResponseProperty("Expiration");
|
||||
this.usingInAppPurchase = this.getResponseProperty("UsingInAppPurchase");
|
||||
const subscription = this.getResponseProperty("Subscription");
|
||||
const upcomingInvoice = this.getResponseProperty("UpcomingInvoice");
|
||||
this.subscription = subscription == null ? null : new BillingSubscriptionResponse(subscription);
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
import { PaymentMethodType } from "../../billing/enums";
|
||||
|
||||
export class IapCheckRequest {
|
||||
paymentMethodType: PaymentMethodType;
|
||||
}
|
||||
@@ -96,7 +96,6 @@ import { DeviceType } from "../enums";
|
||||
import { CollectionBulkDeleteRequest } from "../models/request/collection-bulk-delete.request";
|
||||
import { DeleteRecoverRequest } from "../models/request/delete-recover.request";
|
||||
import { EventRequest } from "../models/request/event.request";
|
||||
import { IapCheckRequest } from "../models/request/iap-check.request";
|
||||
import { KdfRequest } from "../models/request/kdf.request";
|
||||
import { KeysRequest } from "../models/request/keys.request";
|
||||
import { OrganizationImportRequest } from "../models/request/organization-import.request";
|
||||
@@ -382,10 +381,6 @@ export class ApiService implements ApiServiceAbstraction {
|
||||
return new PaymentResponse(r);
|
||||
}
|
||||
|
||||
async postIapCheck(request: IapCheckRequest): Promise<any> {
|
||||
return this.send("POST", "/accounts/iap-check", request, true, false);
|
||||
}
|
||||
|
||||
postReinstatePremium(): Promise<any> {
|
||||
return this.send("POST", "/accounts/reinstate-premium", null, true, false);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user