Skip to content

Commit

Permalink
GET user
Browse files Browse the repository at this point in the history
  • Loading branch information
marcusbuffett committed Oct 23, 2020
1 parent 4918c91 commit 3216cb1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ type EndpointResult<T> = Result<T, ServerError>;

#[get("/users/<username>")]
fn get_user(db: State<Database>, username: String) -> EndpointResult<Json<User>> {
todo!()
Ok(Json(db.users.get(username.as_bytes())??))
}

#[delete("/users/<username>")]
Expand Down

0 comments on commit 3216cb1

Please sign in to comment.