setAuthToken static method

Future<void> setAuthToken(
  1. String token
)

Update the auth token dynamically (after login/OTP)

Implementation

static Future<void> setAuthToken(String token) async {
  _dio?.options.headers['Authorization'] = 'Bearer $token';
  await TokenStorage.saveToken(token);
}