— Lean converts the mongo document to plain object.
This is the only problem. I would've done it but users are not stored in mongodb. Im fetching them from firebase
— Unfortunately not. I know this's is quite inefficient but im doing as "they" suggested
— Oh god.
— Ok this is unfortunate :D
— Supoose, if I've thousand users. How inefficient this would be.
— It'll go crazy with ton of queries.
— Tell something abt this
— Why is it retuning am empty array.
— Means it's getting called even before the async func.
— You call listAllUsers before it is defined