Skip to content

Commit ba378f3

Browse files
committed
Small fixes to make the code compilable for Scala 2.13
1 parent 6abc2bb commit ba378f3

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

openai-client/src/main/scala/io/cequence/openaiscala/JsonUtil.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ object JsonUtil {
2121
}
2222

2323
def asSafeArray[T](implicit fjs: Reads[T]): Seq[T] =
24-
json.asSafe[JsArray].value.map(
24+
json.asSafe[JsArray].value.toSeq.map(
2525
_.asSafe[T]
2626
)
2727
}

openai-guice/src/main/scala/io/cequence/openaiscala/service/GuiceContainer.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ trait GuiceContainer {
1919
protected def instance[T: Manifest] = injector.instance[T]
2020

2121
protected def result[T](future: Future[T]) =
22-
Await.result(future, 100 minutes)
22+
Await.result(future, 100.minutes)
2323

2424
protected def terminate: Unit = {
2525
val system = instance[ActorSystem]
2626
system.terminate
27-
Await.result(system.whenTerminated, 1 day)
27+
Await.result(system.whenTerminated, 1.day)
2828
}
2929
}

0 commit comments

Comments
 (0)