chore: add another method for base64 util
This commit is contained in:
1 file changed
+4
@@ -20,3 +20,7 @@ fun ByteArray.encodeToBase64(): String {
|
||||
fun String.decodeToString(): String {
|
||||
return String(Base64.getDecoder().decode(this))
|
||||
}
|
||||
|
||||
fun String.decodeToByteArray(): ByteArray {
|
||||
return Base64.getDecoder().decode(this)
|
||||
}
|
||||
Reference in New Issue
Block a user