anchor.diff:  %% @private
   %% @doc
   %% Prepares options for hackney. Analyses ssl_options passed in Opts list
  -%% and transfors them in connect_opts, which will be fed to etls:connect.
  -%% @end
  -%%--------------------------------------------------------------------
  --spec prepare_ssl_opts(Opts :: hackney_opts()) -> Opts :: hackney_opts().
  -prepare_ssl_opts(Opts) ->
  +%% and transforms them into connect_opts, which will be fed to etls:connect.
  +%% @end
  +%%--------------------------------------------------------------------
  +-spec prepare_etls_opts(Opts :: hackney_opts()) -> Opts :: hackney_opts().
  +prepare_etls_opts(Opts) ->
       SSLOpts = proplists:get_value(ssl_options, Opts, []),
       ConnectOpts = case proplists:get_value(insecure, Opts) of
           true ->
  
positive.code:     % @todo maybe it is connected with using custom transport
      % @todo   and hackney calls some callback from default one
      % @todo maybe its etls problem
      Opts3 = [{pool, false} | Opts2],
      HeadersProplist = maps:to_list(Headers),
      Result = case hackney:request(Method, HcknURL2, HeadersProplist, Body, Opts3) of
          {error, closed} ->
              % If {error, closed} appears, retry once.
              hackney:request(Method, HcknURL2, HeadersProplist, Body, Opts3);
          OkResult ->
              OkResult
      end,
  
negative.code: %%--------------------------------------------------------------------
  -spec do_request(Method :: method(), URL :: url(),
      Headers :: headers(), Body :: body(), Opts :: hackney_opts()) ->
      Response :: response() | {ok, StreamRef :: term()}.
  do_request(Method, URL, Headers, Body, Opts) ->
      HackneyUrl = hackney_url:parse_url(URL),
      SslLib = proplists:get_value(ssl_lib, Opts, etls),
      % Depending on selected ssl_lib, set proper options
      % (applicable only to HTTPS requests)
      {HackneyUrl2, Opts2} = case {HackneyUrl#hackney_url.transport, SslLib} of
          {hackney_ssl_transport, etls} ->
              % Use etls for HTTPS connections
              {
                  HackneyUrl#hackney_url{transport = hackney_etls_transport},
                  prepare_etls_opts(Opts)
              };
          _ ->
              % Otherwise, just use default hackney behaviour
              % (HTTP and HTTPS with erlang SSL)
              {
                  HackneyUrl,
                  Opts
              }
      end,
      % Do not use hackney pools = new connection every request.
      % When hackney uses socket pools, sometimes it grabs a
      % disconnected socket and returns {error, closed}.
  