summaryrefslogtreecommitdiff
path: root/src/server/activitypub.ts
diff options
context:
space:
mode:
authorMeiMei <30769358+mei23@users.noreply.github.com>2018-11-16 05:47:29 +0900
committersyuilo <Syuilotan@yahoo.co.jp>2018-11-16 05:47:29 +0900
commitbceb02d760f53877f0f677144bc468ffbc4e66f2 (patch)
treecc12d9836b81deecead9417c8fd6df635784fefd /src/server/activitypub.ts
parent[Client] Add missing icon (diff)
downloadsharkey-bceb02d760f53877f0f677144bc468ffbc4e66f2.tar.gz
sharkey-bceb02d760f53877f0f677144bc468ffbc4e66f2.tar.bz2
sharkey-bceb02d760f53877f0f677144bc468ffbc4e66f2.zip
local only visibility (#3254)
* local only visibility * fix UI
Diffstat (limited to 'src/server/activitypub.ts')
-rw-r--r--src/server/activitypub.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/server/activitypub.ts b/src/server/activitypub.ts
index 8da933a0f6..888feb08ce 100644
--- a/src/server/activitypub.ts
+++ b/src/server/activitypub.ts
@@ -66,7 +66,8 @@ router.get('/notes/:note', async (ctx, next) => {
const note = await Note.findOne({
_id: new mongo.ObjectID(ctx.params.note),
- visibility: { $in: ['public', 'home'] }
+ visibility: { $in: ['public', 'home'] },
+ localOnly: { $ne: true }
});
if (note === null) {
@@ -83,7 +84,8 @@ router.get('/notes/:note', async (ctx, next) => {
router.get('/notes/:note/activity', async ctx => {
const note = await Note.findOne({
_id: new mongo.ObjectID(ctx.params.note),
- visibility: { $in: ['public', 'home'] }
+ visibility: { $in: ['public', 'home'] },
+ localOnly: { $ne: true }
});
if (note === null) {