From 88d1251c03398ad8a63bb776f1c9d559ef76e04e Mon Sep 17 00:00:00 2001 From: Chris Bell Date: Thu, 10 Aug 2023 18:03:35 -0400 Subject: [PATCH] fix: types for users.getSubscriptions (#34) --- src/resources/users/index.ts | 6 ++++-- src/resources/users/interfaces.ts | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/resources/users/index.ts b/src/resources/users/index.ts index 558f425..3a403eb 100644 --- a/src/resources/users/index.ts +++ b/src/resources/users/index.ts @@ -24,10 +24,12 @@ import { Knock } from "../../knock"; import { BulkIdentifyUser, IdentifyProperties, + ListSubscriptionsOptions, ListUserOptions, User, UserFeedOptions, } from "./interfaces"; +import { ObjectSubscription } from "../objects/interfaces"; export class Users { constructor(readonly knock: Knock) {} @@ -378,8 +380,8 @@ export class Users { async getSubscriptions( userId: string, - filteringOptions: ListSchedulesProps = {}, - ): Promise> { + filteringOptions: ListSubscriptionsOptions = {}, + ): Promise> { if (!userId) { throw new Error(`Incomplete arguments. You must provide a 'userId'`); } diff --git a/src/resources/users/interfaces.ts b/src/resources/users/interfaces.ts index 70238c8..2799bed 100644 --- a/src/resources/users/interfaces.ts +++ b/src/resources/users/interfaces.ts @@ -37,3 +37,5 @@ export interface ListUserOptions extends PaginationOptions { email?: string; user_id?: string; } + +export interface ListSubscriptionsOptions extends PaginationOptions {} \ No newline at end of file