pub fn crate_location(&self, crate_name: &str, version: &str) -> String {
        match *self {
            Uploader::S3 {
                ref bucket,
                ref cdn,
                ..
            } => {
                let host = match *cdn {
                    Some(ref s) => s.clone(),
                    None => bucket.host(),
                };
                let path = Uploader::crate_path(crate_name, version);
                format!("https://{host}/{path}")
            }
            Uploader::Local => format!("/{}", Uploader::crate_path(crate_name, version)),
        }
    }
/// Returns the URL of an uploaded crate's version archive.
///
/// The function doesn't check for the existence of the file.
Returns the URL of an uploaded crate's version archive.
The function doesn't check for the existence of the file.
Returns the URL of an uploaded crate ' s version archive . The function doesn ' t check for the existence of the file .
pub fn crate_location(&self, crate_name: &str, version: &str) -> String {
        match *self {
            Uploader::S3 {
                ref bucket,
                ref cdn,
                ..
            } => {
                let host = match *cdn {
                    Some(ref s) => s.clone(),
                    None => bucket.host(),
                };
                let path = Uploader::crate_path(crate_name, version);
                format!("https://{host}/{path}")
            }
            Uploader::Local => format!("/{}", Uploader::crate_path(crate_name, version)),
        }
    }
pub fn crate_location ( & self , crate_name : & str , version : & str ) -> String { match * self { Uploader :: S3 { ref bucket , ref cdn , .. } => { let host = match * cdn { Some ( ref s ) => s . clone ( ) , None => bucket . host ( ) , } ; let path = Uploader :: crate_path ( crate_name , version ) ; format ! ( " " ) } Uploader :: Local => format ! ( " " Uploader crate_path ( crate_name version ) ) , } }
Returns the URL of an uploaded crate's version archive.
Returns the URL of an uploaded crate ' s version archive .
&self
crate_name
&str
version
&str