From 467fa421393c768172703683979bcca0e39f398d Mon Sep 17 00:00:00 2001 From: Matt Lee Date: Thu, 4 Jun 2015 17:20:28 -0700 Subject: [PATCH] Sharing: Don't use the short domain for sharing. --- r2/r2/lib/template_helpers.py | 3 --- r2/r2/public/static/js/post-sharing.js | 5 +---- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/r2/r2/lib/template_helpers.py b/r2/r2/lib/template_helpers.py index b7054389c..110193679 100644 --- a/r2/r2/lib/template_helpers.py +++ b/r2/r2/lib/template_helpers.py @@ -200,9 +200,6 @@ def js_config(extra_config=None): if g.uncompressedJS: config["uncompressedJS"] = True - if g.shortdomain: - config["short_domain"] = g.shortdomain - if extra_config: config.update(extra_config) diff --git a/r2/r2/public/static/js/post-sharing.js b/r2/r2/public/static/js/post-sharing.js index c753d1aca..dbcd276c7 100644 --- a/r2/r2/public/static/js/post-sharing.js +++ b/r2/r2/public/static/js/post-sharing.js @@ -149,13 +149,11 @@ var id = fullname.split('_')[1]; var title = $thing.find('.entry a.title').text(); var link = $thing.find('.entry a.comments').attr('href'); - var shortLink = r.config.short_domain ? 'http://' + r.config.short_domain + '/' + id : null; this.thingData = { fullname: fullname, title: title, link: link, - shortLink: shortLink, }; var props = this.options.props || {}; @@ -232,13 +230,12 @@ }, getShareLink: function(refSource) { - var link = this.thingData.shortLink || this.thingData.link; var refParams = { ref: 'share', ref_source: refSource, }; - return replaceParams(link, refParams); + return replaceParams(this.thingData.link, refParams); }, shareToFacebook: function() { -- 2.11.4.GIT