Typing Prisma Wrapper Function

public async getUser(
    { provider, accountId }: Partial<{ provider: string; accountId: string }>,
    include?: Prisma.UserInclude
  ) {
    return await this.prisma.user.findFirst({
      where: {
        accounts: {
          some: {
            accountId,
            provider,
          },
        },
      },
      include: include,
    });
  }

How can I type the return value of this to reflect what is passed into include?
Was this page helpful?