mirror of
https://github.com/AleoHQ/leo.git
synced 2024-12-11 10:22:33 +03:00
fix package
This commit is contained in:
parent
6e68444e59
commit
6a6e8d536d
@ -70,6 +70,10 @@ impl Api {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn host(&self) -> &str {
|
||||
&*self.host
|
||||
}
|
||||
|
||||
/// Get token for bearer auth, should be passed into Api through Context
|
||||
pub fn auth_token(&self) -> Option<String> {
|
||||
self.auth_token.clone()
|
||||
|
@ -17,7 +17,7 @@
|
||||
use super::build::Build;
|
||||
use crate::{
|
||||
commands::Command,
|
||||
context::{Context, PACKAGE_MANAGER_URL},
|
||||
context::{Context},
|
||||
};
|
||||
use leo_package::{
|
||||
outputs::OutputsDirectory,
|
||||
@ -118,7 +118,7 @@ impl Command for Publish {
|
||||
|
||||
// Make a request to publish a package
|
||||
let response = client
|
||||
.post(format!("{}{}", PACKAGE_MANAGER_URL, PUBLISH_URL).as_str())
|
||||
.post(format!("{}{}", context.api.host(), PUBLISH_URL).as_str())
|
||||
.headers(headers)
|
||||
.multipart(form_data)
|
||||
.send();
|
||||
|
Loading…
Reference in New Issue
Block a user