I have the following code whenever I need to access the database, which is everywhere:
withSession {implicit session : Session =>
...
}
How do I stop having to type so much?
I have the following code whenever I need to access the database, which is everywhere:
withSession {implicit session : Session =>
...
}
How do I stop having to type so much?
Copyright © 2021 Jogjafile Inc.
Here is a pattern for this: http://slick.typesafe.com/doc/2.0.0-RC1/connection.html#passing-sessions-around
Also the
:Session
goes away in Slick 2.0