code: private Response retrieveResponseFromCache(Request request, @Nullable Response response) {
          Response.Builder cachedResponse;
          if (response != null) {
              cachedResponse = response.newBuilder();
          } else {
              cachedResponse = new Response.Builder()
                      .request(request)
                      .protocol(Protocol.HTTP_1_1);
          }
          String cached = retrieveFromCache(request.url().toString());
          if (cached != null) {
              return cachedResponse
                      .code(200)
                      .body(ResponseBody.create(
                                      MediaType.parse("application/json"),
                                      cached)
                      ).build();
          } else {
              return response;
          }
      }
docs: Retrieve a {@link Response} from the offline layer.
  
  @param request  request for which an offline response must be retrieved
  @param response original response which lead to an offline access. Can be null.
  @return offline response or null if no response can be retrieve from the offline layer.