Changeset 1049

Show
Ignore:
Timestamp:
07/03/06 12:25:11
Author:
jbisbee
Message:

* Fixes #137
* Changed IKC connection error message to something that will point

the user in the right direction...

Plagger::Plugin::Notify
IRC [error] unable to connect to
plagger-ircbot process at localhost:9991, if you're not
running plagger-ircbot, you should be able to start it
with the same Notify
IRC config you passed to plagger.
Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/plagger/lib/Plagger/Plugin/Notify/IRC.pm

    r1019 r1049  
    1717    my($self, $context, $args) = @_; 
    1818 
     19    my $host = $self->conf->{daemon_host} || 'localhost', 
     20    my $port = $self->conf->{daemon_port} || 9999; 
     21 
    1922    my $remote = POE::Component::IKC::ClientLite::create_ikc_client( 
    20         port    => $self->conf->{daemon_port} || 9999
    21         ip      => $self->conf->{daemon_host} || 'localhost'
     23        port    => $port
     24        ip      => $host
    2225        name    => "Plagger$$", 
    2326        timeout => 5, 
     
    2528 
    2629    unless ($remote) { 
    27         $context->log(error => $POE::Component::IKC::ClientLite::error); 
     30        my $msg = q{unable to connect to plagger-ircbot process on }  
     31            . "$host:$port" 
     32            . q{, if you're not running plagger-ircbot, you should be able } 
     33            . q{to start it with the same Notify::IRC config you passed to } 
     34            . q{plagger. }; 
     35        $context->log( error => $msg ); 
    2836        return; 
    2937    }