Skip to content

Commit 3be3588

Browse files
committed
reformat
1 parent 5ef0577 commit 3be3588

File tree

5 files changed

+7
-11
lines changed

5 files changed

+7
-11
lines changed

core/src/main/java/com/softwaremill/session/javadsl/SessionDirectives.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ import com.softwaremill.session._
1010
import scala.compat.java8.OptionConverters._
1111

1212
/**
13-
* Java alternative for com.softwaremill.session.SessionDirectives
14-
*/
13+
* Java alternative for com.softwaremill.session.SessionDirectives
14+
*/
1515
trait SessionDirectives extends OneOffSessionDirectives with RefreshableSessionDirectives {
1616

1717
def session[T](sc: SessionContinuity[T], st: GetSessionTransport, inner: java.util.function.Function[SessionResult[T], Route]): Route = RouteAdapter {

example/src/main/scala/com/softwaremill/example/ScalaExample.scala

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,9 @@ object Example extends App with StrictLogging {
6363
// This should be protected and accessible only when logged in
6464
path("current_login") {
6565
get {
66-
myRequiredSession { session =>
67-
ctx =>
68-
logger.info("Current session: " + session)
69-
ctx.complete(session.username)
66+
myRequiredSession { session => ctx =>
67+
logger.info("Current session: " + session)
68+
ctx.complete(session.username)
7069
}
7170
}
7271
}

example/src/main/scala/com/softwaremill/example/serializers/JWTSerializersScala.scala

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import org.json4s.ext.JavaTypesSerializers
44
import org.json4s.jackson.Serialization
55
import org.json4s.{Formats, NoTypeHints}
66

7-
87
class JWTSerializersScala {
98

109
implicit lazy val formats: Formats = Serialization.formats(NoTypeHints) ++ JavaTypesSerializers.all

example/src/main/scala/com/softwaremill/example/serializers/MyScalaMultiValueSessionSerializer.scala

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,4 @@ import scala.util.Try
77

88
class MyScalaMultiValueSessionSerializer extends MultiValueSessionSerializer[SomeScalaComplexObject](
99
(sco: SomeScalaComplexObject) => Map("value" -> sco.value),
10-
(m: Map[String, String]) => Try(new SomeScalaComplexObject(m("value")))
11-
)
10+
(m: Map[String, String]) => Try(new SomeScalaComplexObject(m("value"))))

example/src/main/scala/com/softwaremill/example/session/MyScalaSession.scala

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,5 @@ object MyScalaSession {
1111
_.username,
1212
(un: String) => Try {
1313
MyScalaSession(un)
14-
}
15-
)
14+
})
1615
}

0 commit comments

Comments
 (0)