summary refs log tree commit diff
path: root/contrib/vertobot/bot.pl
diff options
context:
space:
mode:
authorKegan Dougal <kegan@matrix.org>2015-03-16 10:09:15 +0000
committerKegan Dougal <kegan@matrix.org>2015-03-16 10:09:15 +0000
commitf9232c7917322de392921336b4bab5d85c213c4e (patch)
treeab55547f1c895da508e6ac37c8056fef5b3b754e /contrib/vertobot/bot.pl
parentFix remaining scheduler bugs. Add more informative logging. (diff)
parentadd ToC and fix typoe (diff)
downloadsynapse-f9232c7917322de392921336b4bab5d85c213c4e.tar.xz
Merge branch 'develop' into application-services-txn-reliability
Conflicts:
	synapse/storage/appservice.py
Diffstat (limited to 'contrib/vertobot/bot.pl')
-rwxr-xr-xcontrib/vertobot/bot.pl9
1 files changed, 4 insertions, 5 deletions
diff --git a/contrib/vertobot/bot.pl b/contrib/vertobot/bot.pl
index 828fc48786..0430a38aa8 100755
--- a/contrib/vertobot/bot.pl
+++ b/contrib/vertobot/bot.pl
@@ -175,13 +175,12 @@ sub on_room_message
 my $verto_connecting = $loop->new_future;
 $bot_verto->connect(
     %{ $CONFIG{"verto-bot"} },
-    on_connected => sub {
-        warn("[Verto] connected to websocket");
-        $verto_connecting->done($bot_verto) if not $verto_connecting->is_done;
-    },
     on_connect_error => sub { die "Cannot connect to verto - $_[-1]" },
     on_resolve_error => sub { die "Cannot resolve to verto - $_[-1]" },        
-);
+)->then( sub { 
+    warn("[Verto] connected to websocket");
+    $verto_connecting->done($bot_verto) if not $verto_connecting->is_done;
+});
 
 Future->needs_all(
     $bot_matrix->login( %{ $CONFIG{"matrix-bot"} } )->then( sub {