Namanl2001 / MERN-Gurujii-dev

⭐️ Helps! in finding Tutors.
https://guru-jii.herokuapp.com/
MIT License
34 stars 85 forks source link

Better logic for the name filter #219

Closed tend2infinity closed 3 years ago

tend2infinity commented 3 years ago

Describe the bug Right now the name filter is using a very lazy logic in which we are just comparing if our input name is exactly similar to any name in our database. This gives us only a single query as a result. What we can do is use something called .includes() through which we can produce multiple meaningful outputs if our input string matches with any sub-string from the names of tutors!