mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-11-10 09:03:08 +02:00
Fix bug
This commit is contained in:
parent
299ec075e2
commit
a774767676
1 changed files with 13 additions and 0 deletions
|
@ -3,6 +3,7 @@
|
||||||
:class="{ wait, active: isFollowing || hasPendingFollowRequestFromYou, full }"
|
:class="{ wait, active: isFollowing || hasPendingFollowRequestFromYou, full }"
|
||||||
@click="onClick"
|
@click="onClick"
|
||||||
:disabled="wait"
|
:disabled="wait"
|
||||||
|
v-if="isFollowing != null"
|
||||||
>
|
>
|
||||||
<template v-if="!wait">
|
<template v-if="!wait">
|
||||||
<template v-if="hasPendingFollowRequestFromYou && user.isLocked">
|
<template v-if="hasPendingFollowRequestFromYou && user.isLocked">
|
||||||
|
@ -57,6 +58,18 @@ export default Vue.extend({
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|
||||||
|
created() {
|
||||||
|
// 渡されたユーザー情報が不完全な場合
|
||||||
|
if (this.user.isFollowing == null) {
|
||||||
|
this.$root.api('users/show', {
|
||||||
|
userId: this.user.id
|
||||||
|
}).then(u => {
|
||||||
|
this.isFollowing = u.isFollowing;
|
||||||
|
this.hasPendingFollowRequestFromYou = u.hasPendingFollowRequestFromYou;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
mounted() {
|
mounted() {
|
||||||
this.connection = this.$root.stream.useSharedConnection('main');
|
this.connection = this.$root.stream.useSharedConnection('main');
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue