irc icon indicating copy to clipboard operation
irc copied to clipboard

send_mode(target, modes) only sends first mode when more then one mode is specified.

Open Ep0chalypse opened this issue 3 years ago • 0 comments

When using either Client or Sender's send_mode(target, modes) function only the first mode in the array is set.

For example this will only set mode #channel +v nickname

sender.send_mode(&channel, &[
          Mode::Plus(ChannelMode::Voice, Some(nickname.to_string())),
          Mode::Plus(ChannelMode::Oper, Some(nickname.to_string()))
 ])?;

Or this will only set mode #channel +o nickname

sender.send_mode(&channel, &[
          Mode::Plus(ChannelMode::Oper, Some(nickname.to_string())),
          Mode::Plus(ChannelMode::Voice, Some(nickname.to_string()))
 ])?;

Other info:

  • irc crate: 0.15.0
  • rust: 1.59.0
  • network: EFnet

Ep0chalypse avatar Mar 30 '22 00:03 Ep0chalypse