summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/keys.rs2
-rw-r--r--src/release.rs4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/keys.rs b/src/keys.rs
index aca310b..72ab86d 100644
--- a/src/keys.rs
+++ b/src/keys.rs
@@ -80,6 +80,6 @@ impl LoginInfo {
}
pub fn api_for(&self, url: &Url) -> Result<forgejo_api::Forgejo, forgejo_api::ForgejoError> {
- forgejo_api::Forgejo::new(&self.key, url.clone())
+ forgejo_api::Forgejo::new(forgejo_api::Auth::Token(&self.key), url.clone())
}
}
diff --git a/src/release.rs b/src/release.rs
index bbd1225..9661fb5 100644
--- a/src/release.rs
+++ b/src/release.rs
@@ -400,11 +400,11 @@ async fn download_asset(
let release = find_release(repo, api, &release).await?;
let file = match &*asset {
"source.zip" => {
- api.download_release_zip(repo.owner(), repo.name(), release.id)
+ api.download_zip_archive(repo.owner(), repo.name(), &release.tag_name)
.await?
}
"source.tar.gz" => {
- api.download_release_tarball(repo.owner(), repo.name(), release.id)
+ api.download_tarball_archive(repo.owner(), repo.name(), &release.tag_name)
.await?
}
name => {