pike.git / lib / modules / Web.pmod / Api.pmod / Api.pike

version» Context lines:

pike.git/lib/modules/Web.pmod/Api.pmod/Api.pike:574:   }      //! Returns the encoding from a response   //!   //! @param h   //! The headers mapping from a HTTP respose   protected string get_encoding(mapping h)   {    if (h["content-type"]) {    sscanf(h["content-type"], "%*scharset=%s", string s); -  return s && lower_case(String.trim_all_whites(s)) || ""; +  return s && lower_case(String.trim(s)) || "";    }       return "";   }      //! Unescapes escaped forward slashes in a JSON string   protected string unescape_forward_slashes(string s)   {    return replace(s, "\\/", "/");   }