@1castro https://github.com/pichalite/nodebb-plugin-emailer-mailjet/pull/3
It is up to @pichalite now.
@Nicolas In this case... you're calling getUsersData, and that just makes a call to MongoDB passing in the uids. If you pass in invalid uids (that is, perhaps they don't exist or were deleted, as you say), then it will return null.
Best to filter as advised. In @rspk's case, he's running a forum with migrated data.