Skip to content

Commit

Permalink
Merge pull request #2 from jifalops/pr-test-2
Browse files Browse the repository at this point in the history
test pr
  • Loading branch information
jifalops authored Dec 2, 2024
2 parents f158a3f + 7793641 commit 9190535
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# API Rust

[![.github/workflows/test.yml](https://github.com/jifalops/api-rust/actions/workflows/test.yml/badge.svg)](https://github.com/jifalops/api-rust/actions/workflows/test.yml)

[![.github/workflows/deploy_lambda.yml](https://github.com/jifalops/api-rust/actions/workflows/deploy_lambda.yml/badge.svg)](https://github.com/jifalops/api-rust/actions/workflows/deploy_lambda.yml)

A template repo for building a Rust/Axum API using a dev-container.
Expand Down
4 changes: 2 additions & 2 deletions lib/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ async fn handler() -> Html<&'static str> {

pub async fn auth<A: App>(State(app): State<Arc<A>>) -> Json<&'static str> {
match app.auth().authenticate("valid").await {
Ok(()) => Json("authenticated!"),
Err(()) => Json("unauthenticated!"),
Ok(()) => Json("authenticated"),
Err(()) => Json("unauthenticated"),
}
}

0 comments on commit 9190535

Please sign in to comment.