feat(web): add accepting subscription invites from UI
This commit is contained in:
@@ -38,7 +38,7 @@ describe('SubscriptionServer', () => {
|
||||
})
|
||||
|
||||
it('should accept an invite to a shared subscription', async () => {
|
||||
httpService.get = jest.fn().mockReturnValue({
|
||||
httpService.post = jest.fn().mockReturnValue({
|
||||
data: { success: true },
|
||||
} as jest.Mocked<SubscriptionInviteAcceptResponse>)
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@ export class SubscriptionServer implements SubscriptionServerInterface {
|
||||
constructor(private httpService: HttpServiceInterface) {}
|
||||
|
||||
async acceptInvite(params: SubscriptionInviteAcceptRequestParams): Promise<SubscriptionInviteAcceptResponse> {
|
||||
const response = await this.httpService.get(Paths.v1.acceptInvite(params.inviteUuid), params)
|
||||
const response = await this.httpService.post(Paths.v1.acceptInvite(params.inviteUuid), params)
|
||||
|
||||
return response as SubscriptionInviteAcceptResponse
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user