mirror of
https://github.com/paricafe/misskey.git
synced 2024-11-28 00:16:44 -06:00
fix handling of private renotes
Signed-off-by: eternal-flame-AD <yume@yumechi.jp>
This commit is contained in:
parent
437dbbe75d
commit
77705d34d1
2 changed files with 6 additions and 2 deletions
|
@ -7,6 +7,7 @@ import { setImmediate } from 'node:timers/promises';
|
|||
import * as mfm from 'mfm-js';
|
||||
import { In, DataSource, IsNull, LessThan } from 'typeorm';
|
||||
import * as Redis from 'ioredis';
|
||||
import * as Bull from 'bullmq';
|
||||
import { Inject, Injectable, OnApplicationShutdown } from '@nestjs/common';
|
||||
import { extractMentions } from '@/misc/extract-mentions.js';
|
||||
import { extractCustomEmojisFromMfm } from '@/misc/extract-custom-emojis-from-mfm.js';
|
||||
|
@ -295,7 +296,7 @@ export class NoteCreateService implements OnApplicationShutdown {
|
|||
case 'followers':
|
||||
// 他人のfollowers noteはreject
|
||||
if (data.renote.userId !== user.id) {
|
||||
throw new Error('Renote target is not public or home');
|
||||
throw new Bull.UnrecoverableError('Renote target is not public or home');
|
||||
}
|
||||
|
||||
// Renote対象がfollowersならfollowersにする
|
||||
|
@ -303,7 +304,7 @@ export class NoteCreateService implements OnApplicationShutdown {
|
|||
break;
|
||||
case 'specified':
|
||||
// specified / direct noteはreject
|
||||
throw new Error('Renote target is not public or home');
|
||||
throw new Bull.UnrecoverableError('Renote target is not public or home');
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -37,6 +37,9 @@ export interface IObject {
|
|||
tag?: IObject | IObject[];
|
||||
sensitive?: boolean;
|
||||
updated?: string;
|
||||
visibility?: string;
|
||||
mentionedUsers?: any[];
|
||||
visibleUsers?: any[];
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue