This commit is contained in:
2024-01-30 20:55:42 +01:00
parent 2a03f8bed4
commit f404f7804c
2 changed files with 9 additions and 5 deletions

View File

@@ -6,7 +6,7 @@
/* By: vvaas <vvaas@student.42angouleme.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/01/21 10:36:21 by maldavid #+# #+# */
/* Updated: 2024/01/30 20:15:29 by maldavid ### ########.fr */
/* Updated: 2024/01/30 20:50:31 by vvaas ### ########.fr */
/* */
/******************************************************************************/
@@ -134,7 +134,7 @@ namespace irc
void Channel::showModes(unstd::SharedPtr<Client> client)
{
std::string modes = " +";
std::string modes = _name + " +";
if(_invite_only)
modes += 'i';
@@ -146,6 +146,8 @@ namespace irc
modes += 'l';
if(modes.size() <= 2)
return ;
if (modes.size() == _name.size() + 2)
return ;
client->sendCode(RPL_CHANNELMODEIS, modes);
}