リモートのカスタム絵文字リアクションを表示できるように (#6239)
* リモートのカスタム絵文字リアクションを表示できるように * AP * DBマイグレーション * ローカルのリアクションの. * fix * fix * fix * space
This commit is contained in:
parent
cda1803e59
commit
9b07c5af05
12 changed files with 185 additions and 41 deletions
|
|
@ -1,7 +1,7 @@
|
|||
import { IRemoteUser } from '../../../models/entities/user';
|
||||
import { ILike, getApId } from '../type';
|
||||
import create from '../../../services/note/reaction/create';
|
||||
import { fetchNote } from '../models/note';
|
||||
import { fetchNote, extractEmojis } from '../models/note';
|
||||
|
||||
export default async (actor: IRemoteUser, activity: ILike) => {
|
||||
const targetUri = getApId(activity.object);
|
||||
|
|
@ -11,6 +11,8 @@ export default async (actor: IRemoteUser, activity: ILike) => {
|
|||
|
||||
if (actor.id === note.userId) return `skip: cannot react to my note`;
|
||||
|
||||
await extractEmojis(activity.tag || [], actor.host).catch(() => null);
|
||||
|
||||
await create(actor, note, activity._misskey_reaction || activity.content || activity.name);
|
||||
return `ok`;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue