Ignore:
Timestamp:
Mar 11, 2009, 6:22:41 PM (16 years ago)
Author:
Nelson Elhage <nelhage@mit.edu>
Branches:
master, debian, release-1.10, release-1.4, release-1.5, release-1.6, release-1.7, release-1.8, release-1.9
Children:
82dd923
Parents:
19aeff4
Message:
IRC: Don't use a default target for irc-msg

Because /msg can take either a user or a channel, it's ambiguous whether
'irc-msg nelhage' with your cursor on a message to #barnowl is supposed
to tell #barnowl 'nelhage', or start a message to nelhage. Resolve this
by just never taking the channel from the current message.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • perl/modules/IRC/lib/BarnOwl/Module/IRC.pm

    rf17bb2c0 re0fba58  
    147147
    148148    BarnOwl::new_command(
    149         'irc-msg' => mk_irc_command( \&cmd_msg, OPTIONAL_CHANNEL ),
     149        'irc-msg' => mk_irc_command( \&cmd_msg ),
    150150        {
    151151            summary => 'Send an IRC message',
     
    380380    my $cmd  = shift;
    381381    my $conn = shift;
    382     my $to = shift || shift or die("Usage: $cmd NICK\n");
     382    my $to = shift or die("Usage: $cmd [NICK|CHANNEL]\n");
    383383    # handle multiple recipients?
    384384    if(@_) {
Note: See TracChangeset for help on using the changeset viewer.