This commit is contained in:
barisusakli
2014-06-13 15:33:22 -04:00
parent ce1934e566
commit 4c2765a79c
10 changed files with 24 additions and 32 deletions

View File

@@ -114,14 +114,9 @@ function sendNotificationToPostOwner(data, uid, notification) {
return;
}
var path = nconf.get('relative_path') + '/topic/' + results.slug;
if (parseInt(results.index, 10)) {
path += '/' + (parseInt(results.index, 10) + 1);
}
notifications.create({
text: '[[' + notification + ', ' + results.username + ']]',
path: path,
path: nconf.get('relative_path') + '/topic/' + results.slug + '/' + results.index,
uniqueId: 'post:' + data.pid,
from: uid
}, function(nid) {
@@ -306,7 +301,7 @@ SocketPosts.flag = function(socket, pid, callback) {
posts.getPidIndex(pid, next);
},
function(postIndex, next) {
path += '/' + (parseInt(postIndex, 10) + 1);
path += '/' + postIndex;
groups.get('administrators', {}, next);
},
function(adminGroup, next) {