aboutsummaryrefslogtreecommitdiff
path: root/src/main.js
diff options
context:
space:
mode:
authorkaniini <nenolod@gmail.com>2018-08-24 18:46:23 +0000
committerkaniini <nenolod@gmail.com>2018-08-24 18:46:23 +0000
commit14db3f279daed82011bdcc2bbad21450c08a4487 (patch)
tree78118003e73a50683903806669a4d4c5f27ea276 /src/main.js
parent0429963e63408a207a0c35b33b728acaab1f0d3d (diff)
parent0647c1bb720144b3d9e3d7943129d0d67d176ab0 (diff)
Merge branch 'feature/who-to-follow-panel-uses-suggestions-api' into 'develop'
Who to follow panel uses suggestions api See merge request pleroma/pleroma-fe!294
Diffstat (limited to 'src/main.js')
-rw-r--r--src/main.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/main.js b/src/main.js
index 06f8a6ec..4124214d 100644
--- a/src/main.js
+++ b/src/main.js
@@ -192,3 +192,11 @@ window.fetch('/instance/panel.html')
store.dispatch('setOption', { name: 'instanceSpecificPanelContent', value: html })
})
+window.fetch('/nodeinfo/2.0.json')
+ .then((res) => res.json())
+ .then((data) => {
+ const suggestions = data.metadata.suggestions
+ store.dispatch('setOption', { name: 'suggestionsEnabled', value: suggestions.enabled })
+ store.dispatch('setOption', { name: 'suggestionsWeb', value: suggestions.web })
+ })
+