Skip to content

Lean query converts to binary when using generic as type #15158

@timheerwagen

Description

@timheerwagen

Prerequisites

  • I have written a descriptive issue title
  • I have searched existing issues to ensure the bug has not already been reported

Mongoose version

8.9.3

Node.js version

22.10.5

MongoDB server version

6.12.0

Typescript version (if applicable)

5.7.2

Description

When using lean query with a generic type of FooBar or object a typescript error gets thrown similar to this error: #15122

My last working version was ^8.7.0.

Steps to Reproduce

Reproduction Link: https://stackblitz.com/edit/vitejs-vite-tstcb3k5?file=src%2Findex.ts

Expected Behavior

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    typescriptTypes or Types-test related issue / Pull Request

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions