1
0
Fork 0
mirror of https://github.com/pgpainless/pgpainless.git synced 2024-12-24 11:57:59 +01:00

Move const to companion object

This commit is contained in:
Paul Schaub 2023-08-31 16:44:26 +02:00
parent d020e7e12c
commit 56d573aec6
Signed by: vanitasvitae
GPG key ID: 62BEE9264BF17311

View file

@ -25,7 +25,6 @@ import java.io.IOException
import java.security.KeyPairGenerator
import java.util.*
const val MILLIS_IN_YEAR = 1000L * 60 * 60 * 24 * 365
class KeyRingBuilder : KeyRingBuilderInterface<KeyRingBuilder> {
@ -225,6 +224,8 @@ class KeyRingBuilder : KeyRingBuilderInterface<KeyRingBuilder> {
}
companion object {
const val MILLIS_IN_YEAR = 1000L * 60 * 60 * 24 * 365
@JvmStatic
fun generateKeyPair(spec: KeySpec): PGPKeyPair {
spec.keyType.let { type ->