Skip to content

Commit

Permalink
#2936 remove community logic
Browse files Browse the repository at this point in the history
  • Loading branch information
Tuan Tuan LE committed Apr 15, 2020
1 parent 89db93d commit 7f2317a
Show file tree
Hide file tree
Showing 48 changed files with 638 additions and 3,301 deletions.
9 changes: 6 additions & 3 deletions backend/core/activitystreams/pubsub.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ module.exports.processActivity = processActivity;
function updateTimelineEntriesTracker(data, callback) {
if (!data) {
logger.warn('Can not create timeline entries tracker from null data');

return;
}

Expand All @@ -48,18 +49,19 @@ function updateTimelineEntriesTracker(data, callback) {
}
};

collaborationModule.queryOne(data.collaboration.objectType, {_id: data.collaboration.id}, function(err, community) {
collaborationModule.queryOne(data.collaboration.objectType, {_id: data.collaboration.id}, function(err, collaboration) {
if (err) {
return callback(err);
}

var options = {
target: {
objectType: 'activitystream',
_id: community.activity_stream.uuid
_id: collaboration.activity_stream.uuid
},
limit: 1
};

activitystream.query(options, function(err, results) {
if (err) {
return callback(err);
Expand All @@ -68,7 +70,7 @@ function updateTimelineEntriesTracker(data, callback) {
return callback(null, null);
}

tracker.updateLastTimelineEntry(data.target, community.activity_stream.uuid, results[0]._id, function(err) {
tracker.updateLastTimelineEntry(data.target, collaboration.activity_stream.uuid, results[0]._id, function(err) {
if (err) {
return callback(err);
}
Expand All @@ -83,6 +85,7 @@ module.exports.updateTimelineEntriesTracker = updateTimelineEntriesTracker;
function init() {
if (initialized) {
logger.warn('Activity Stream Pubsub is already initialized');

return;
}
pubsub.topic('message:activity').subscribe(processActivity);
Expand Down
18 changes: 0 additions & 18 deletions backend/core/community/archive.js

This file was deleted.

19 changes: 0 additions & 19 deletions backend/core/community/constants.js

This file was deleted.

22 changes: 0 additions & 22 deletions backend/core/community/denormalize.js

This file was deleted.

253 changes: 0 additions & 253 deletions backend/core/community/index.js

This file was deleted.

28 changes: 0 additions & 28 deletions backend/core/community/listener.js

This file was deleted.

Loading

0 comments on commit 7f2317a

Please sign in to comment.