This commit is contained in:
stom79 2019-01-16 13:11:56 +01:00
parent 559439193d
commit e4f6ac783a
1 changed files with 2 additions and 6 deletions

View File

@ -2066,16 +2066,12 @@ public class API {
* Retrieves Accounts and feeds when searching *synchronously*
*
* @param query String search
* @return List<Account>
* @return Results
*/
public Results search(String query) {
HashMap<String, String> params = new HashMap<>();
try {
params.put("q", URLEncoder.encode(query, "UTF-8"));
} catch (UnsupportedEncodingException e) {
params.put("q", query);
}
params.put("q", query);
try {
HttpsConnection httpsConnection = new HttpsConnection(context);
String response = httpsConnection.get(getAbsoluteUrl("/search"), 60, params, prefKeyOauthTokenT);