fix(fl_query_hooks): newest query/mutation/infinite-query instance not getting returned

This commit is contained in:
Kingkor Roy Tirtho
2022-09-23 09:50:22 +06:00
parent e0c3d7f4ba
commit 03a053bba6
6 changed files with 6 additions and 15 deletions
@@ -179,13 +179,6 @@ abstract class BaseQuery<T extends Object, Outside, Error>
/// the current available [data] instead of running the task to prevent
/// race conditions
Future<T?> refetch() async {
if (queryKey == "category-playlists#user-featured-playlists") {
print(
"Refetch Count of ${queryKey}-> ${refetchCount}",
);
print(StackTrace.current);
}
/// if isLoading/isRefetching is true that means its already fetching/
/// refetching. So [_execute] again can create a race condition
if (isRefetching || isLoading) return data;