mirror of https://github.com/readrops/Readrops.git
Send the right exception to TimelineTab
This commit is contained in:
parent
6d55c3200a
commit
adb2b0c192
|
@ -94,13 +94,13 @@ class SyncWorker(
|
|||
|
||||
workResult
|
||||
} catch (e: Exception) {
|
||||
Log.e(TAG, "${e::class.simpleName}: ${e.message} ${e.printStackTrace()}")
|
||||
Log.e(TAG, "${e.printStackTrace()}")
|
||||
|
||||
notificationManager.cancel(SYNC_NOTIFICATION_ID)
|
||||
if (isManual) {
|
||||
Result.failure(
|
||||
workDataOf(SYNC_FAILURE_KEY to true)
|
||||
.putSerializable(SYNC_FAILURE_EXCEPTION_KEY, e)
|
||||
.putSerializable(SYNC_FAILURE_EXCEPTION_KEY, Exception(e.cause))
|
||||
)
|
||||
} else {
|
||||
Result.failure()
|
||||
|
|
Loading…
Reference in New Issue