mirror of
https://github.com/fabianonline/telegram_backup.git
synced 2024-11-22 08:46:15 +00:00
Added a convenience method Any.toJson()
This commit is contained in:
parent
28931830eb
commit
93ad47639f
@ -181,3 +181,8 @@ object Utils {
|
||||
fun String.anonymize(): String {
|
||||
return if (!CommandLineOptions.cmd_anonymize) this else this.replace(Regex("[0-9]"), "1").replace(Regex("[A-Z]"), "A").replace(Regex("[a-z]"), "a") + " (ANONYMIZED)"
|
||||
}
|
||||
|
||||
fun Any.toJson(): String {
|
||||
|
||||
return Gson().toJson(this)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user