mirror of
https://github.com/fluencelabs/fluid
synced 2025-06-28 20:41:32 +00:00
rename lots of things
This commit is contained in:
@ -51,7 +51,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
|
||||
|
@ -34,7 +34,7 @@ pub fn get_all_posts() -> AppResult<String> {
|
||||
.map_err(|e| err_msg(&format!("Error retrieving posts: {}", e)))
|
||||
}
|
||||
|
||||
pub fn get_posts_by_handle(username: String) -> AppResult<String> {
|
||||
pub fn get_posts_by_username(username: String) -> AppResult<String> {
|
||||
database::query(format!(
|
||||
"SELECT json_group_array(
|
||||
json_object('msg', msg, 'username', username)
|
||||
|
Reference in New Issue
Block a user