fix(frontend): Plugin:register_note_view_interruptor()によるノートの書き換えが機能しない問題を修正
Fix #16180
This commit is contained in:
parent
b5767c315a
commit
9a3219f12e
|
@ -12,6 +12,7 @@
|
|||
- Fix: コントロールパネルのファイル欄などのデザインが崩れている問題を修正
|
||||
- Fix: ユーザーの検索結果を追加で読み込むことができない問題を修正
|
||||
- Fix: タッチ操作時にチャートのツールチップが消えなくなる場合がある問題を修正
|
||||
- Fix: Plugin:register_note_view_interruptor()によるノートの書き換えが機能しない問題を修正
|
||||
|
||||
### Server
|
||||
- Feat: 全てのチャットメッセージを既読にするAPIを追加(chat/read-all)
|
||||
|
|
|
@ -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);
|
||||
|
|
|
@ -289,17 +289,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);
|
||||
|
|
Loading…
Reference in New Issue