|
@@ -140,11 +140,13 @@ const MyFriendsScreen: FC<Props> = ({ navigation }) => {
|
|
};
|
|
};
|
|
|
|
|
|
const applySort = async () => {
|
|
const applySort = async () => {
|
|
|
|
+ const resetPage = 0;
|
|
|
|
+
|
|
await getMyFriends(
|
|
await getMyFriends(
|
|
{
|
|
{
|
|
token,
|
|
token,
|
|
type: routes[index].key,
|
|
type: routes[index].key,
|
|
- page,
|
|
|
|
|
|
+ page: resetPage,
|
|
sort: filter.ranking,
|
|
sort: filter.ranking,
|
|
age: filter.age,
|
|
age: filter.age,
|
|
country: filter.country
|
|
country: filter.country
|
|
@@ -159,6 +161,7 @@ const MyFriendsScreen: FC<Props> = ({ navigation }) => {
|
|
});
|
|
});
|
|
setMaxPages(data[routes[index].key].max_pages);
|
|
setMaxPages(data[routes[index].key].max_pages);
|
|
setMasterCountries(convertData(data[routes[index].key].countries) ?? []);
|
|
setMasterCountries(convertData(data[routes[index].key].countries) ?? []);
|
|
|
|
+ setPage(resetPage);
|
|
setLoading(false);
|
|
setLoading(false);
|
|
}
|
|
}
|
|
}
|
|
}
|