~jan0sch/smederee
Showing details for patch 1550c2f7f08ad2be475332cc62c53a8266c3a783.
diff -rN -u old-smederee/modules/hub/src/main/scala/de/smederee/hub/types.scala new-smederee/modules/hub/src/main/scala/de/smederee/hub/types.scala --- old-smederee/modules/hub/src/main/scala/de/smederee/hub/types.scala 2025-01-10 20:54:37.681099259 +0000 +++ new-smederee/modules/hub/src/main/scala/de/smederee/hub/types.scala 2025-01-10 20:54:37.681099259 +0000 @@ -84,7 +84,7 @@ * A string containing a base 64 encoded url safe version of the generated random bytes. */ def generate: SessionId = { - var buffer = new Array[Byte](Length) // scalafix:ok; Mutability is needed here for the random generator. + val buffer = new Array[Byte](Length) randomGenerator.nextBytes(buffer) base64Encoder.encodeToString(buffer) }