aboutsummaryrefslogtreecommitdiff
path: root/src/main/assets/embed.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/assets/embed.js')
-rw-r--r--src/main/assets/embed.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/assets/embed.js b/src/main/assets/embed.js
index 739b95f3..0022ae82 100644
--- a/src/main/assets/embed.js
+++ b/src/main/assets/embed.js
@@ -255,10 +255,10 @@ function getEmbeddableLinkTypes() {
div.innerHTML = `<blockquote class="twitter-tweet" data-lang="en"><a href="${url}"></a></blockquote>`;
- if (window.twttr) {
+ if (window['twttr']) {
// this will only happen if you embed another set of twitter posts after the twitter script loads (likely never)
// https://developer.twitter.com/en/docs/twitter-for-websites/javascript-api/guides/scripting-loading-and-initialization
- window.twttr.widgets.load(div);
+ window['twttr'].widgets.load(div);
} else if (!document.head.querySelector ('[src="https://platform.twitter.com/widgets.js\"]')) {
// innerHTML cannot insert scripts, so...
let script = document.createElement('script');