rename lots of things

This commit is contained in:
folex
2019-08-16 12:00:50 +03:00
parent 9dd2a2d9c8
commit 50747bbcd3
47 changed files with 31 additions and 227 deletions

View File

@ -49,7 +49,7 @@ fn fetch_posts(username: Option<String>) -> AppResult<Response> {
// Get all posts if no filter username was passed
None => model::get_all_posts()?,
// Or get only posts from specified author
Some(h) => model::get_posts_by_handle(h)?,
Some(h) => model::get_posts_by_username(h)?,
};
// Some Rust-specific detail to play nice with serialization, doesn't matter

View File

@ -14,7 +14,7 @@ pub fn get_all_posts() -> AppResult<String> {
Ok("[]".to_string())
}
pub fn get_posts_by_handle(username: String) -> AppResult<String> {
pub fn get_posts_by_username(username: String) -> AppResult<String> {
log::info!("get all posts by username {}", username);
Ok("[]".to_string())
}