mirror of
https://github.com/vale981/Vulcan
synced 2025-03-06 01:51:40 -05:00
remove unnecessary decodeUrl (fix #675)
This commit is contained in:
parent
0a5f30ce71
commit
c5ce397c17
1 changed files with 2 additions and 3 deletions
|
@ -7,9 +7,8 @@ Meteor.startup(function (){
|
|||
where: 'server',
|
||||
action: function(){
|
||||
var query = this.request.query;
|
||||
if(query.url){
|
||||
var decodedUrl = decodeURIComponent(query.url);
|
||||
var post = Posts.findOne({url: decodedUrl});
|
||||
if(query.url){ // for some reason, query.url doesn't need to be decoded
|
||||
var post = Posts.findOne({url: query.url});
|
||||
if (post) {
|
||||
var sessionId = Meteor.default_connection && Meteor.default_connection._lastSessionId ? Meteor.default_connection._lastSessionId : null;
|
||||
Meteor.call('increasePostClicks', post._id, sessionId);
|
||||
|
|
Loading…
Add table
Reference in a new issue