Skip to content

Commit 20d585a

Browse files
committed
Bot support
1 parent 1a57cb6 commit 20d585a

3 files changed

Lines changed: 9 additions & 6 deletions

File tree

nodejshelper/bootstrap/bootstrap.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ public function run() {
2222
// Chat was accepted.
2323
$dispatcher->listen('chat.accept', array( $this,'statusChange' ));
2424
$dispatcher->listen('chat.close', array( $this,'statusChange' ));
25+
$dispatcher->listen('chat.genericbot_chat_command_transfer', array( $this,'statusChange' ));
2526
}
2627

2728
public function __get($var)

nodejshelper/design/nodejshelpertheme/js/customjs-widget.js

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
(function() {
1+
setTimeout(function() {
22

33
var socketOptions = {
44
hostname: lh.nodejsHelperOptions.hostname,
@@ -78,13 +78,15 @@
7878
ee.addListener('visitorTypingStopped', visitorTypingStoppedListener);
7979

8080
// Make larger sync interval
81-
confLH.chat_message_sinterval = 15000;
82-
};
81+
confLH.chat_message_sinterval = 10000;
82+
83+
// Force one time check
84+
lhinst.syncusercall();
85+
}
8386
});
8487

8588
$(window).on('beforeunload', function () {
8689
socket.destroy();
8790
});
8891

89-
90-
})();
92+
},1000);

0 commit comments

Comments
 (0)