log_res_interceptor.dart 439 B

123456789101112131415
  1. import 'dart:async';
  2. import 'package:get/get_connect/http/src/request/request.dart';
  3. import 'package:get/get_connect/http/src/response/response.dart';
  4. import 'package:ftrecruiter/comm/utils/log_utils.dart';
  5. //打印响应信息
  6. FutureOr<dynamic> logResInterceptor(Request request, Response response) async {
  7. // 输出结果
  8. Log.d('ResponseCode: ${response.statusCode} , ResponseHeaders:${response.headers}}');
  9. return response;
  10. }