Skip to content
This repository has been archived by the owner on Nov 14, 2024. It is now read-only.

Commit

Permalink
removed indentation syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-ciocirlan committed Nov 8, 2023
1 parent 5313bc2 commit c702c0e
Show file tree
Hide file tree
Showing 3 changed files with 140 additions and 121 deletions.
11 changes: 6 additions & 5 deletions _posts/2023-04-21-security-in-http4s.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ import cats.effect.*
import org.http4s.*
import org.http4s.dsl.io.*

object CorsExample extends IOApp{
object CorsExample extends IOApp {
val imageService = HttpRoutes.of[IO]{
case GET -> Root / "image" / name =>
Ok(s"Processing image: $name." )
Expand Down Expand Up @@ -263,7 +263,7 @@ import org.http4s.server.middleware.CORS
import org.http4s.headers.Origin


object securityHttp4s extends IOApp{
object securityHttp4s extends IOApp {
val imageService = HttpRoutes.of[IO]{
case GET -> Root / "image" / name =>
Ok(s"Processing image: $name." )
Expand All @@ -282,7 +282,8 @@ object securityHttp4s extends IOApp{
.withHttpApp(corsService)
.build

override def run(args: List[String]): IO[ExitCode] = server.use(_ => IO.never).as(ExitCode.Success)
override def run(args: List[String]): IO[ExitCode] =
server.use(_ => IO.never).as(ExitCode.Success)
}
```
Expand Down Expand Up @@ -368,7 +369,7 @@ import org.http4s.dsl.io.*
import org.http4s.ember.server.EmberServerBuilder
import com.comcast.ip4s.*
object csrfExample extends IOApp{
object csrfExample extends IOApp {
val service = HttpRoutes.of[IO]{
case GET -> Root / "testing" =>
Ok(s"Testing" )
Expand Down Expand Up @@ -569,7 +570,7 @@ import cats.effect.unsafe.IORuntime
import org.http4s.server.middleware.CSRF
import javax.crypto.SecretKey
object csrfExample extends IOApp{
object csrfExample extends IOApp {
val photoService = HttpRoutes.of[IO]{
case GET -> Root / "testing" =>
Expand Down
Loading

0 comments on commit c702c0e

Please sign in to comment.