Повторный вход в аккаунт, очистка кэша
This commit is contained in:
@@ -57,6 +57,8 @@ Future<void> initDependencies() async {
|
||||
dio.interceptors.add(InterceptorsWrapper(
|
||||
onRequest: (options, handler) {
|
||||
final token = prefs.getString('access_token');
|
||||
// ignore: avoid_print
|
||||
print('[DEBUG] Dio Request: ${options.path}, Token present: ${token != null}');
|
||||
if (token != null) {
|
||||
options.headers['Authorization'] = 'Bearer $token';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user