From 6f300357e247ce0645acdff25d2f0b1c056d3ae1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs?= Date: Sat, 21 Sep 2019 11:54:56 -0500 Subject: Polyfill setTimeout if missing from vAPI --- js/vapi-client.js | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'js/vapi-client.js') diff --git a/js/vapi-client.js b/js/vapi-client.js index aeddd81..68da828 100644 --- a/js/vapi-client.js +++ b/js/vapi-client.js @@ -32,6 +32,12 @@ let vAPI = self.vAPI; + vAPI.setTimeout = vAPI.setTimeout || function (callback, delay, extra) { + return setTimeout(function (a) { + callback(a); + }, delay, extra); + }; + vAPI.sessionId = String.fromCharCode(Date.now() % 25 + 97) + Math.random().toString(36).slice(2); -- cgit v1.2.3