Skip to content
This repository has been archived by the owner on Feb 5, 2023. It is now read-only.

Commit

Permalink
fix: update followers counts
Browse files Browse the repository at this point in the history
  • Loading branch information
Candinya committed Sep 7, 2021
1 parent 3e4d965 commit d103062
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/views/Home.vue
Original file line number Diff line number Diff line change
Expand Up @@ -315,9 +315,6 @@ export default class Home extends Vue {
this.rss3Profile.bio = profile?.bio || '';
this.rss3Profile.address = this.ethAddress;
this.rss3Relations.followers = (await this.rss3?.backlinks.get(this.ethAddress, 'following')) || [];
this.rss3Relations.followings = (await this.rss3?.links.get(this.ethAddress, 'following'))?.list || [];
if (data) {
this.accounts.push({
platform: 'Ethereum',
Expand Down Expand Up @@ -419,8 +416,13 @@ export default class Home extends Vue {
if (RSS3.isValidRSS3()) {
if (this.isFollowing) {
await this.unfollow();
this.rss3Relations.followers.splice(
this.rss3Relations.followers.indexOf((<IRSS3>this.rss3).account.address),
1,
);
} else {
await this.follow();
this.rss3Relations.followers.push((<IRSS3>this.rss3).account.address);
}
await (<IRSS3>this.rss3).files.sync();
} else {
Expand Down

0 comments on commit d103062

Please sign in to comment.