Merge pull request #166 from krawieck/fix/private-follows

This commit is contained in:
Filip Krawczyk 2021-02-25 22:16:32 +01:00 committed by GitHub
commit 8ffe97961e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 18 deletions

View File

@ -14,6 +14,7 @@ WARNING: due to some internal changes your local settings will be reset (logged
- Titles on some pages, have an appear affect when scrolling down
- Long pressing comments now has a ripple effect
- Nerd stuff now contains more nerd stuff
- Communities that a user follows will no longer appear on a user's profile in most scenarios
### Fixed

View File

@ -53,6 +53,7 @@ class CommunitiesTab extends HookWidget {
savedOnly: false,
userId:
accountsStore.defaultTokenFor(instanceHost).payload.id,
auth: accountsStore.defaultTokenFor(instanceHost).raw,
))
.then((e) => e.follows),
)

View File

@ -388,32 +388,23 @@ class _AboutTab extends HookWidget {
..sort((a, b) => a.community.name.compareTo(b.community.name)))
communityTile(
comm.community.name, comm.community.icon, comm.community.id),
divider
divider,
],
ListTile(
title: Center(
child: Text(
'Subscribed:',
style: theme.textTheme.headline6.copyWith(fontSize: 18),
if (userDetails.follows.isNotEmpty) ...[
ListTile(
title: Center(
child: Text(
'Subscribed:',
style: theme.textTheme.headline6.copyWith(fontSize: 18),
),
),
),
),
if (userDetails.follows.isNotEmpty)
for (final comm
in userDetails.follows
..sort((a, b) => a.community.name.compareTo(b.community.name)))
communityTile(
comm.community.name, comm.community.icon, comm.community.id)
else
const Padding(
padding: EdgeInsets.only(top: 8),
child: Center(
child: Text(
'this user does not subscribe to any community',
style: TextStyle(fontStyle: FontStyle.italic),
),
),
)
]
],
);
}