Improve installer & related UI
This commit is contained in:
@@ -20,6 +20,8 @@
|
||||
package com.aurora.extensions
|
||||
|
||||
import android.text.format.DateFormat
|
||||
import java.io.PrintWriter
|
||||
import java.io.StringWriter
|
||||
import java.util.*
|
||||
|
||||
fun Long.toDate(): String {
|
||||
@@ -27,3 +29,11 @@ fun Long.toDate(): String {
|
||||
calendar.timeInMillis = this
|
||||
return DateFormat.format("dd/MM/yy", calendar).toString()
|
||||
}
|
||||
|
||||
fun Throwable.stackTraceToString(): String {
|
||||
val stringWriter = StringWriter(1024)
|
||||
val printWriter = PrintWriter(stringWriter)
|
||||
printStackTrace(printWriter)
|
||||
printWriter.close()
|
||||
return stringWriter.toString()
|
||||
}
|
||||
Reference in New Issue
Block a user