You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 16, 2023. It is now read-only.
Hello,
I have tried ng-chat and am new in socket.io world. I am trying to create friendlist with specific user group whose data will render from database. But I am not abling.Would please advice me my list is like this:
`router.get("/chat", (req, res, next) => {
ALUser.find({
$and: [{
uniname: {
'$regex': req.query.uniname,
'$options': 'i'
}
},
{
dept: {
'$regex': req.query.dept,
'$options': 'i'
}
},
{
session: {
'$regex': req.query.session,
'$options': 'i'
}
}
]
}).then(data => {
res.status(200).json({
message: "Users retrieved successfully!",
alusers: data
});
});
});
var usersCollection = [];
app.post('/alumnichat', function (req, res) {
var clonedArray = usersCollection.slice();
// Getting the userId from the request body as this is just a demo
// Ideally in a production application you would change this to a session value or something else
var i = usersCollection.findIndex(x => x.participant.id == req.body.userId);
clonedArray.splice(i, 1);
res.json(clonedArray);
});`
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hey!
You have a gr8 module here! (I'm the 92 ⭐️)
do you have an option to change the group chat title so it wouldn't show participants' names rather the topic we are discussing?
The text was updated successfully, but these errors were encountered: