Skip to content

Commit de59257

Browse files
authored
Merge pull request #28 from fundhuesped/chatbot-fix
Chatbot fix
2 parents bf66018 + 1aaf2a3 commit de59257

File tree

1 file changed

+9
-5
lines changed
  • public/scripts/home/controllers/home

1 file changed

+9
-5
lines changed

public/scripts/home/controllers/home/view.html

+9-5
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,15 @@
4646
<!-- START Botmaker WebChat-->
4747
<script>
4848
(function () {
49-
let js = document.createElement('script');
50-
js.type = 'text/javascript';
51-
js.async = 1;
52-
js.src = 'https://go.botmaker.com/rest/webchat/p/HLENDRUDLS/init.js';
53-
document.body.appendChild(js);
49+
let readyExecuted = false;
50+
51+
if (!readyExecuted) {
52+
let js = document.createElement('script');
53+
js.type = 'text/javascript';
54+
js.async = 1;
55+
js.src = 'https://go.botmaker.com/rest/webchat/p/HLENDRUDLS/init.js';
56+
document.body.appendChild(js);
57+
}
5458
})();
5559
</script>
5660
<!-- END Botmaker WebChat-->

0 commit comments

Comments
 (0)