diff --git a/app/assets/javascripts/discourse/controllers/share.js.es6 b/app/assets/javascripts/discourse/controllers/share.js.es6 index 975f591fa9a..abf8cd081dd 100644 --- a/app/assets/javascripts/discourse/controllers/share.js.es6 +++ b/app/assets/javascripts/discourse/controllers/share.js.es6 @@ -26,6 +26,6 @@ export default Ember.Controller.extend({ }, sources: function() { - return Sharing.activeSources(); + return Sharing.activeSources(this.siteSettings.share_links); }.property() }); diff --git a/app/assets/javascripts/discourse/lib/sharing.js.es6 b/app/assets/javascripts/discourse/lib/sharing.js.es6 index f8d2e4fe406..e695119c704 100644 --- a/app/assets/javascripts/discourse/lib/sharing.js.es6 +++ b/app/assets/javascripts/discourse/lib/sharing.js.es6 @@ -31,8 +31,7 @@ export default { _sources[source.id] = source; }, - activeSources() { - const enabled = Discourse.SiteSettings.share_links.split('|'); - return enabled.map(s => _sources[s]).compact(); + activeSources(linksSetting) { + return linksSetting.split('|').map(s => _sources[s]).compact(); } };