Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DocumentNotFoundError in findOne method #783

Open
erfanetoon opened this issue Aug 5, 2024 · 3 comments
Open

DocumentNotFoundError in findOne method #783

erfanetoon opened this issue Aug 5, 2024 · 3 comments
Assignees

Comments

@erfanetoon
Copy link

erfanetoon commented Aug 5, 2024

We use Ottoman as an ORM in our project,

When we use the findOne method, and the item is not found on the server, it responds with a DocumentNotFoundError even though we have set the enforceRefCheck property to true . This property is intended to enforce reference checks, but it seems ignored.

We found in your source code that you just checked the length of response data, and you ignored the enforceRefCheck property,
image

My first question is, Why do you ignore enforceRefCheck ?
And, How can we ignore this error in the2.4.0 version ?

We don't need to throw an error when a document is not found on the server.

@arabsoheyl
Copy link

+1

@a1993azad
Copy link

I have the same bug.

@hessaam
Copy link

hessaam commented Aug 6, 2024

This has been my eldest issue with Ottoman since I used it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants