]> iEval git - app-fonbot-daemon.git/blobdiff - lib/App/FonBot/Plugin/HTTPD.pm
Bump version and update Changes
[app-fonbot-daemon.git] / lib / App / FonBot / Plugin / HTTPD.pm
index 555ba375ad897dc74b89ee27436addfebd54e16f..1efec362990f6b4f3ce5b20623cc2bad7cbd08ec 100644 (file)
@@ -1,6 +1,6 @@
 package App::FonBot::Plugin::HTTPD;
 
-our $VERSION = '0.000_4';
+our $VERSION = '0.001';
 
 use v5.14;
 use strict;
@@ -33,7 +33,7 @@ sub init{
        %waiting_requests = ();
        %waiting_userrequests = ();
        $httpd = POE::Component::Server::HTTP->new(
-               Port => 8888,
+               Port => $httpd_port,
                PreHandler => { '/' => [\&pre_auth, \&pre_get, \&pre_userget], },
                ContentHandler =>{ '/send' => \&on_send, '/get' => \&on_get, '/ok' => \&on_ok, '/userget' => \&on_userget, '/usersend' => \&on_usersend },
                ErrorHandler => { '/' => sub { RC_OK }},
@@ -196,7 +196,7 @@ sub on_send{
 
                if ($driver eq 'HTTP') {
                        $responses{$user}//=[];
-                       push $responses{$user}, $content;
+                       push @{$responses{$user}}, $content;
                        if (exists $waiting_userrequests{$user}) {
                                $waiting_userrequests{$user}->continue;
                                delete $waiting_userrequests{$user}
@@ -304,7 +304,7 @@ Marius Gavrilescu C<< marius@ieval.ro >>
 
 =head1 COPYRIGHT AND LICENSE
 
-Copyright 2013 Marius Gavrilescu
+Copyright 2013-2015 Marius Gavrilescu
 
 This file is part of fonbotd.
 
This page took 0.020305 seconds and 4 git commands to generate.