From de80225125a1318cff323b266dec23709f6a353c Mon Sep 17 00:00:00 2001 From: vipin9821 <50833659+Vipin9821@users.noreply.github.com> Date: Mon, 1 Apr 2024 17:35:55 +0530 Subject: [PATCH] [CacheInterceptor] Fix auto refresh functionality --- lib/src/interceptors/cache_interceptor.dart | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/src/interceptors/cache_interceptor.dart b/lib/src/interceptors/cache_interceptor.dart index 0f6c2c8..47adb39 100644 --- a/lib/src/interceptors/cache_interceptor.dart +++ b/lib/src/interceptors/cache_interceptor.dart @@ -60,7 +60,8 @@ abstract class ApiCacheInterceptor extends Interceptor { ), ); if (!isValid) { - if (keyData['appSpecificHeaders']?['ignoreAutoRefresh'] ?? false) { + if (options.headers['appSpecificHeaders']?['ignoreAutoRefresh'] ?? + false) { return null; } refreshCache(options);