fix promise error

This commit is contained in:
feruz 2021-01-18 22:06:22 +02:00
parent 09a608adc4
commit 1249988983
3 changed files with 4 additions and 3 deletions

View File

@ -715,4 +715,4 @@ SPEC CHECKSUMS:
PODFILE CHECKSUM: 1f30c7da5061dbc47185442a6ab4a3c95ac48c04
COCOAPODS: 1.10.0
COCOAPODS: 1.9.3

View File

@ -314,7 +314,8 @@ export const getCommunities = async (
resolve({});
}
} catch (error) {
reject(error);
console.log(error);
resolve({});
}
});

View File

@ -46,7 +46,7 @@ const CommunitiesResultsContainer = ({ children, navigation, searchValue }) => {
setNoResult(false);
getSubscriptions(currentAccount.username).then((subs) => {
getCommunities('', searchValue ? 250 : 20, searchValue, 'rank').then((communities) => {
getCommunities('', searchValue ? 100 : 20, searchValue, 'rank').then((communities) => {
communities.forEach((community) =>
Object.assign(community, {
isSubscribed: subs.some(