Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if (true) {
- var iframeContEl = document.getElementById('tgme_frame_cont') || document.body;
- var iframeEl = document.createElement('iframe');
- iframeContEl.appendChild(iframeEl);
- var pageHidden = false;
- window.addEventListener('pagehide', function () {
- pageHidden = true;
- }, false);
- window.addEventListener('blur', function () {
- pageHidden = true;
- }, false);
- if (iframeEl !== null) {
- iframeEl.src = "tg:\/\/resolve?domain=GitHubBot";
- }
- setTimeout(function() {
- if (!pageHidden) {
- window.location = "tg:\/\/resolve?domain=GitHubBot";
- }
- }, 2000);
- } else {
- setTimeout(function() {
- window.location = "tg:\/\/resolve?domain=GitHubBot";
- }, 100);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement