chore (client): remove unnecessary non-null assertions
This commit is contained in:
parent
a49f9c33ef
commit
c6d0fe52d2
5 changed files with 6 additions and 6 deletions
|
@ -8,7 +8,7 @@
|
|||
<i :class="icon('ph-dots-three-outline')"></i>
|
||||
</button>
|
||||
<button
|
||||
v-if="!hideFollowButton && isSignedIn(me) && me!.id != user.id"
|
||||
v-if="!hideFollowButton && isSignedIn(me) && me.id != user.id"
|
||||
v-tooltip="full ? null : `${state} ${user.name || user.username}`"
|
||||
class="kpoogebi _button follow-button"
|
||||
:class="{
|
||||
|
|
|
@ -53,7 +53,7 @@ const url = `/${canonical}`;
|
|||
const isMe =
|
||||
isSignedIn(me) &&
|
||||
`@${props.username}@${toUnicode(props.host)}`.toLowerCase() ===
|
||||
`@${me!.username}@${toUnicode(localHost)}`.toLowerCase();
|
||||
`@${me.username}@${toUnicode(localHost)}`.toLowerCase();
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
|
|
|
@ -370,7 +370,7 @@ const reactButton = ref<HTMLElement | null>(null);
|
|||
const appearNote = computed(() =>
|
||||
isRenote ? (note.value.renote as NoteType) : note.value,
|
||||
);
|
||||
const isMyRenote = isSignedIn(me) && me!.id === note.value.userId;
|
||||
const isMyRenote = isSignedIn(me) && me.id === note.value.userId;
|
||||
// const showContent = ref(false);
|
||||
const isDeleted = ref(false);
|
||||
const muted = ref(
|
||||
|
|
|
@ -77,7 +77,7 @@ const hasRenotedBefore = ref(false);
|
|||
if (isSignedIn(me)) {
|
||||
os.api("notes/renotes", {
|
||||
noteId: props.note.id,
|
||||
userId: me!.id,
|
||||
userId: me.id,
|
||||
limit: 1,
|
||||
}).then((res) => {
|
||||
hasRenotedBefore.value = res.length > 0;
|
||||
|
|
|
@ -59,7 +59,7 @@
|
|||
<div class="other">
|
||||
<button
|
||||
v-if="
|
||||
isSignedIn(me) && me!.id === post.user.id
|
||||
isSignedIn(me) && me.id === post.user.id
|
||||
"
|
||||
v-tooltip="i18n.ts.toEdit"
|
||||
v-click-anime
|
||||
|
@ -105,7 +105,7 @@
|
|||
<MkAcct :user="post.user" />
|
||||
</div>
|
||||
<MkFollowButton
|
||||
v-if="!isSignedIn(me) || me!.id != post.user.id"
|
||||
v-if="!isSignedIn(me) || me.id != post.user.id"
|
||||
:user="post.user"
|
||||
:inline="true"
|
||||
:transparent="false"
|
||||
|
|
Loading…
Reference in a new issue