diff --git a/js/plugins.js b/js/plugins.js index 8297762..038f260 100644 --- a/js/plugins.js +++ b/js/plugins.js @@ -564,30 +564,24 @@ plugins.factory('userPlugins', function() { if (match) { return function() { + fetch("https://www.tiktok.com/oembed?url=" + url) + .then(function(response) { + return response.json(); + }) + .then(function(data) { + // separate the HTML into content and script tag + var scriptIndex = data.html.indexOf("