fix: null error in renote button
This commit is contained in:
parent
fd3d788aad
commit
c21a24ee92
1 changed files with 10 additions and 7 deletions
|
@ -73,6 +73,8 @@ useTooltip(buttonRef, async (showing) => {
|
|||
});
|
||||
|
||||
const hasRenotedBefore = ref(false);
|
||||
|
||||
if ($i != null) {
|
||||
os.api("notes/renotes", {
|
||||
noteId: props.note.id,
|
||||
userId: $i.id,
|
||||
|
@ -80,6 +82,7 @@ os.api("notes/renotes", {
|
|||
}).then((res) => {
|
||||
hasRenotedBefore.value = res.length > 0;
|
||||
});
|
||||
}
|
||||
|
||||
const renote = (viaKeyboard = false, ev?: MouseEvent) => {
|
||||
pleaseLogin();
|
||||
|
|
Loading…
Reference in a new issue