Hunter0x7c7
2023-08-11 198dd6e1b210758867eed417bf6e00ba733d47c0
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package com.github.hunter0x7c7.sync.model.server.net.interceptors;
 
import okhttp3.Interceptor;
import okhttp3.Response;
 
import java.io.IOException;
 
/**
 * 拦截,http缓存
 */
public class RestInterceptors implements Interceptor {
 
    @Override
    public Response intercept(Chain chain) throws IOException {
        try {
            return chain.proceed(chain.request());
        } catch (Exception e) {
            e.printStackTrace();
        }
        return new Response.Builder().build();
    }
}