Skip to content

Commit

Permalink
Share count: Cleanup, compress and final fixes #2
Browse files Browse the repository at this point in the history
  • Loading branch information
darklow committed Feb 5, 2015
1 parent ed9892e commit 6a32664
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 14 deletions.
14 changes: 2 additions & 12 deletions dist/js/social-share-kit.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@ var SocialShareKit = (function () {
if (el.parentNode.className.indexOf('ssk-count') !== -1) {
//networksToCount.push(network);
network = network[0];
var shareUrl = getShareUrl(network, el),
uniqueKey = network + sep + shareUrl;
uniqueKey = network + sep + getShareUrl(network, el);
if (!(uniqueKey in urlsToCount)) {
urlsToCount[uniqueKey] = [];
}
Expand Down Expand Up @@ -262,18 +261,9 @@ var SocialShareKit = (function () {
};
break;
}
url && parseFunc && JSONPRequest(url, parseFunc);
url && parseFunc && JSONPRequest(network, url, parseFunc);
}


var VK = {
Share: {
count: function (value, count) {
$('#vkontakte_count').html(count);
}
}
};

function JSONPRequest(network, url, callback) {
var callbackName = 'cb_' + network + '_' + Math.round(100000 * Math.random()),
script = document.createElement('script');
Expand Down
4 changes: 2 additions & 2 deletions dist/js/social-share-kit.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 6a32664

Please sign in to comment.