diff --git a/dbTools/profile.js b/dbTools/profile.js index 74c334c..c543810 100644 --- a/dbTools/profile.js +++ b/dbTools/profile.js @@ -39,6 +39,7 @@ userDB = (DB) => { DB.getProfile = async (profileId) => { //if (userProfileCache[profileId] && !userProfileCache[profileId].isGroup) return userProfileCache[profileId]; + if(!profileId) return false; const _id = DB.ObjectID(profileId); let r = await DB.profileCols.findOne({ _id }).catch((err) => { console.log(err);