summaryrefslogtreecommitdiffstats
path: root/src/lib.rs
diff options
context:
space:
mode:
authorCyborus <cyborus@cyborus.xyz>2024-01-18 23:48:10 +0100
committerCyborus <cyborus@cyborus.xyz>2024-01-18 23:53:11 +0100
commitbfb31fc296e3447b16290b8cff1ce5c1deed2e1d (patch)
tree800df916f9e9e4ac54953ccefea1938db1b2b59d /src/lib.rs
parentstrip leading slash (diff)
downloadforgejo-api-bfb31fc296e3447b16290b8cff1ce5c1deed2e1d.tar.xz
forgejo-api-bfb31fc296e3447b16290b8cff1ce5c1deed2e1d.zip
add trailing slash to api prefix
Diffstat (limited to 'src/lib.rs')
-rw-r--r--src/lib.rs10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib.rs b/src/lib.rs
index 23ae513..90e6cc6 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -137,27 +137,27 @@ impl Forgejo {
}
fn get(&self, path: &str) -> reqwest::RequestBuilder {
- let url = self.url.join("api/v1").unwrap().join(path).unwrap();
+ let url = self.url.join("api/v1/").unwrap().join(path).unwrap();
self.client.get(url)
}
fn put(&self, path: &str) -> reqwest::RequestBuilder {
- let url = self.url.join("api/v1").unwrap().join(path).unwrap();
+ let url = self.url.join("api/v1/").unwrap().join(path).unwrap();
self.client.put(url)
}
fn post(&self, path: &str) -> reqwest::RequestBuilder {
- let url = self.url.join("api/v1").unwrap().join(path).unwrap();
+ let url = self.url.join("api/v1/").unwrap().join(path).unwrap();
self.client.post(url)
}
fn delete(&self, path: &str) -> reqwest::RequestBuilder {
- let url = self.url.join("api/v1").unwrap().join(path).unwrap();
+ let url = self.url.join("api/v1/").unwrap().join(path).unwrap();
self.client.post(url)
}
fn patch(&self, path: &str) -> reqwest::RequestBuilder {
- let url = self.url.join("api/v1").unwrap().join(path).unwrap();
+ let url = self.url.join("api/v1/").unwrap().join(path).unwrap();
self.client.post(url)
}