Fixed URL format in Gitea probing.
This commit is contained in:
parent
8f4ff59a6a
commit
a2eee04e72
1 changed files with 3 additions and 3 deletions
|
@ -56,15 +56,15 @@ public class GiteaAPI
|
|||
this.token = token;
|
||||
|
||||
//
|
||||
String json = IOUtils.toString(new URL(url + "/api/v1/admin/users?limit=100000&token=" + token), Charset.defaultCharset());
|
||||
String json = IOUtils.toString(new URL(this.url + "/api/v1/admin/users?limit=100000&token=" + token), Charset.defaultCharset());
|
||||
this.users = (JSONArray) (new JSONParser().parse(json));
|
||||
|
||||
//
|
||||
json = IOUtils.toString(new URL(url + "/api/v1/admin/orgs?limit=100000&token=" + token), Charset.defaultCharset());
|
||||
json = IOUtils.toString(new URL(this.url + "/api/v1/admin/orgs?limit=100000&token=" + token), Charset.defaultCharset());
|
||||
this.organizations = (JSONArray) (new JSONParser().parse(json));
|
||||
|
||||
//
|
||||
json = IOUtils.toString(new URL(url + "/api/v1/repos/search?limit=100000&token=" + token), Charset.defaultCharset());
|
||||
json = IOUtils.toString(new URL(this.url + "/api/v1/repos/search?limit=100000&token=" + token), Charset.defaultCharset());
|
||||
this.repositories = (JSONArray) ((JSONObject) (new JSONParser().parse(json))).get("data");
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue