Drop the get_ prefix for functions
This commit is contained in:
parent
11b32acfb4
commit
11c78a6cc8
|
@ -91,8 +91,8 @@ pub(crate) async fn download(file: PathBuf, backend: &str) -> Result<Redirect> {
|
|||
/// Handler for retrieving the RSS feed of user on a certain back-end.
|
||||
#[get("/feed/<backend>/<username>")]
|
||||
async fn feed(backend: &str, username: &str, config: &State<Config>) -> Result<RssFeed> {
|
||||
let user = mixcloud::get_user(username).await?;
|
||||
let cloudcasts = mixcloud::get_cloudcasts(username).await?;
|
||||
let user = mixcloud::user(username).await?;
|
||||
let cloudcasts = mixcloud::cloudcasts(username).await?;
|
||||
let mut last_build = DateTime::<Utc>::from_utc(NaiveDateTime::from_timestamp(0, 0), Utc);
|
||||
|
||||
let category = CategoryBuilder::default()
|
||||
|
|
|
@ -115,7 +115,7 @@ pub(crate) fn estimated_file_size(duration: u32) -> u32 {
|
|||
time = 3600,
|
||||
result = true
|
||||
)]
|
||||
pub(crate) async fn get_user(username: &str) -> Result<User> {
|
||||
pub(crate) async fn user(username: &str) -> Result<User> {
|
||||
let mut url = Url::parse(API_BASE_URL).expect("URL can always be parsed");
|
||||
url.set_path(username);
|
||||
|
||||
|
@ -133,7 +133,7 @@ pub(crate) async fn get_user(username: &str) -> Result<User> {
|
|||
time = 3600,
|
||||
result = true
|
||||
)]
|
||||
pub(crate) async fn get_cloudcasts(username: &str) -> Result<Vec<Cloudcast>> {
|
||||
pub(crate) async fn cloudcasts(username: &str) -> Result<Vec<Cloudcast>> {
|
||||
let mut url = Url::parse(API_BASE_URL).expect("URL can always be parsed");
|
||||
url.set_path(&format!("{username}/cloudcasts/"));
|
||||
|
||||
|
|
Loading…
Reference in New Issue