Skip to content

Instantly share code, notes, and snippets.

@adamw
Last active September 20, 2019 06:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save adamw/5919f235d3d8b239e202ab39a6e03112 to your computer and use it in GitHub Desktop.
Save adamw/5919f235d3d8b239e202ab39a6e03112 to your computer and use it in GitHub Desktop.
val sendEmail: IO[Unit] = IO(println("Sending email"))
val sendEmailWithConnection: ConnectionIO[Unit] =
sendEmail.to[ConnectionIO]
val sendEmailInTx: IO[Unit] = sendEmailWithConnection.transact(transactor)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment