mirror of
https://github.com/misskey-dev/misskey.git
synced 2026-05-01 16:15:50 +02:00
fix(frontend): Plugin:register_note_view_interruptor()によるノートの書き換えが機能しない問題を修正
Fix #16180
This commit is contained in:
@@ -268,17 +268,15 @@ let note = deepClone(props.note);
|
||||
// plugin
|
||||
const noteViewInterruptors = getPluginHandlers('note_view_interruptor');
|
||||
if (noteViewInterruptors.length > 0) {
|
||||
onMounted(async () => {
|
||||
let result: Misskey.entities.Note | null = deepClone(note);
|
||||
for (const interruptor of noteViewInterruptors) {
|
||||
try {
|
||||
result = await interruptor.handler(result!) as Misskey.entities.Note | null;
|
||||
} catch (err) {
|
||||
console.error(err);
|
||||
}
|
||||
let result: Misskey.entities.Note | null = deepClone(note);
|
||||
for (const interruptor of noteViewInterruptors) {
|
||||
try {
|
||||
result = await interruptor.handler(result!) as Misskey.entities.Note | null;
|
||||
} catch (err) {
|
||||
console.error(err);
|
||||
}
|
||||
note = result as Misskey.entities.Note;
|
||||
});
|
||||
}
|
||||
note = result as Misskey.entities.Note;
|
||||
}
|
||||
|
||||
const isRenote = Misskey.note.isPureRenote(note);
|
||||
|
||||
Reference in New Issue
Block a user