Fix Flavor values in Utils

This commit is contained in:
Adolfo Santiago 2022-01-22 09:29:58 +01:00
parent bcf653da28
commit 68e9138d62
No known key found for this signature in database
GPG key ID: 244D6F9A317B4A65

View file

@ -22,20 +22,20 @@ package com.keylesspalace.tusky.core.utils
enum class Flavor(private val flavor: String) { enum class Flavor(private val flavor: String) {
BETA("huskyBeta"), BETA("huskyBeta"),
DEV("huskyStable"); STABLE("huskyStable");
companion object { companion object {
/** /**
* Get the flavor enum (recommended use: using <code>Flavor.<FLAVOR></code> * Get the flavor enum (recommended use: using <code>Flavor.<FLAVOR></code>
* (<FLAVOR>: DEV, PRE, PROD). * (<FLAVOR>: BETA, STABLE).
* *
* @param flavor The name of the Flavor. * @param flavor The name of the Flavor.
*/ */
fun getFlavor(flavor: String) = fun getFlavor(flavor: String) =
when(flavor) { when(flavor) {
BETA.flavor -> DEV BETA.flavor -> BETA
else -> DEV else -> STABLE
} }
} }
} }