aboutsummaryrefslogtreecommitdiffstats
path: root/app/src/main/java/com/zeapo/pwdstore/autofill/AutofillService.kt
diff options
context:
space:
mode:
authorHarsh Shandilya <msfjarvis@gmail.com>2020-01-26 11:35:10 +0530
committerGitHub <noreply@github.com>2020-01-26 11:35:10 +0530
commit2c78470642905fbaedbda02801e716dd33b70cb5 (patch)
tree5848829657dfd350d2c9b4892b9338ec1c563620 /app/src/main/java/com/zeapo/pwdstore/autofill/AutofillService.kt
parent14f1fa65381375149dbb3fcdba578b6b4799645e (diff)
downloadHardenedPass-2c78470642905fbaedbda02801e716dd33b70cb5.tar.gz
HardenedPass-2c78470642905fbaedbda02801e716dd33b70cb5.zip
Switch to Timber for logging (#617)
* Switch to Timber for logging Signed-off-by: Harsh Shandilya <msfjarvis@gmail.com> * Update changelog Signed-off-by: Harsh Shandilya <msfjarvis@gmail.com> * Fix rebase error Signed-off-by: Harsh Shandilya <msfjarvis@gmail.com>
Diffstat (limited to 'app/src/main/java/com/zeapo/pwdstore/autofill/AutofillService.kt')
-rw-r--r--app/src/main/java/com/zeapo/pwdstore/autofill/AutofillService.kt10
1 files changed, 5 insertions, 5 deletions
diff --git a/app/src/main/java/com/zeapo/pwdstore/autofill/AutofillService.kt b/app/src/main/java/com/zeapo/pwdstore/autofill/AutofillService.kt
index 24c4b1f5..249455ec 100644
--- a/app/src/main/java/com/zeapo/pwdstore/autofill/AutofillService.kt
+++ b/app/src/main/java/com/zeapo/pwdstore/autofill/AutofillService.kt
@@ -17,7 +17,6 @@ import android.net.Uri
import android.os.Build
import android.os.Bundle
import android.provider.Settings
-import android.util.Log
import android.view.ViewGroup.LayoutParams.WRAP_CONTENT
import android.view.WindowManager
import android.view.accessibility.AccessibilityEvent
@@ -45,6 +44,7 @@ import me.msfjarvis.openpgpktx.util.OpenPgpServiceConnection
import org.apache.commons.io.FileUtils
import org.openintents.openpgp.IOpenPgpService2
import org.openintents.openpgp.OpenPgpError
+import timber.log.Timber
class AutofillService : AccessibilityService() {
private var serviceConnection: OpenPgpServiceConnection? = null
@@ -518,11 +518,11 @@ class AutofillService : AccessibilityService() {
lastPasswordMaxDate = System.currentTimeMillis() + ttl * 1000L
}
} catch (e: UnsupportedEncodingException) {
- Log.e(Constants.TAG, "UnsupportedEncodingException", e)
+ Timber.tag(Constants.TAG).e(e, "UnsupportedEncodingException")
}
}
OpenPgpApi.RESULT_CODE_USER_INTERACTION_REQUIRED -> {
- Log.i("PgpHandler", "RESULT_CODE_USER_INTERACTION_REQUIRED")
+ Timber.tag("PgpHandler").i("RESULT_CODE_USER_INTERACTION_REQUIRED")
val pi = result.getParcelableExtra<PendingIntent>(OpenPgpApi.RESULT_INTENT)
// need to start a blank activity to call startIntentSenderForResult
val intent = Intent(this@AutofillService, AutofillActivity::class.java)
@@ -536,8 +536,8 @@ class AutofillService : AccessibilityService() {
Toast.makeText(this@AutofillService,
"Error from OpenKeyChain : " + error.message,
Toast.LENGTH_LONG).show()
- Log.e(Constants.TAG, "onError getErrorId:" + error.errorId)
- Log.e(Constants.TAG, "onError getMessage:" + error.message)
+ Timber.tag(Constants.TAG).e("onError getErrorId: ${error.errorId}")
+ Timber.tag(Constants.TAG).e("onError getMessage: ${error.message}")
}
}
}