Updated the uppercase and lowercase
This commit is contained in:
parent
6deb73600d
commit
9b328c93c7
@ -14,7 +14,7 @@ open class MoneyCurrency(
|
||||
private var configs: Map<String, Any?>? = null,
|
||||
) : Serializable, StdMoney.Currency {
|
||||
override fun getCurrency(): String {
|
||||
return name.toUpperCase().trim()
|
||||
return name.uppercase().trim()
|
||||
}
|
||||
|
||||
fun getSymbol(): String? {
|
||||
|
@ -8,7 +8,7 @@ infix fun StdMoney.exchangeTo(currency: StdMoney.Currency): StdMoney {
|
||||
|
||||
infix fun StdMoney.exchangeTo(currency: String): StdMoney = this exchangeTo object : StdMoney.Currency {
|
||||
override fun getCurrency(): String {
|
||||
return currency.toUpperCase().trim()
|
||||
return currency.uppercase().trim()
|
||||
}
|
||||
}
|
||||
|
||||
@ -69,7 +69,7 @@ infix fun Number.withCurrency(currency: StdMoney.Currency): StdMoney = object :
|
||||
|
||||
infix fun Number.withCurrency(currency: String): StdMoney = this withCurrency object : StdMoney.Currency {
|
||||
override fun getCurrency(): String {
|
||||
return currency.toUpperCase().trim()
|
||||
return currency.uppercase().trim()
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -105,7 +105,7 @@ open class MoneyObject(
|
||||
if (temp.length == 1) {
|
||||
operator(temp[0])
|
||||
} else {
|
||||
valueOf(temp.toUpperCase().trim())
|
||||
valueOf(temp.uppercase().trim())
|
||||
}
|
||||
}
|
||||
is Char -> {
|
||||
|
@ -60,7 +60,7 @@ interface StdMoney : MoneyMixin {
|
||||
fun initCurrency(currency: String?): Currency {
|
||||
return object : Currency {
|
||||
override fun getCurrency(): String {
|
||||
return currency?.toUpperCase()?.trim() ?: "USD"
|
||||
return currency?.uppercase()?.trim() ?: "USD"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user