Skip to content

Commit

Permalink
...
Browse files Browse the repository at this point in the history
  • Loading branch information
MFlisar committed Oct 30, 2020
1 parent 8fd1371 commit 3be2248
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ object LogHelper {
}

fun clearLogFiles() {
// do NOT delete all files directly, just delete old ones and clear the newest one => the folling function does do that for you
// do NOT delete all files directly, just delete old ones and clear the newest one => the following function does do that for you
FILE_LOGGING_SETUP.clearLogFiles()
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.michaelflisar.lumberjack.data

import android.util.Log
import com.michaelflisar.lumberjack.L
import java.util.regex.Pattern

Expand Down Expand Up @@ -74,12 +75,13 @@ class StackData {
// ------------------------

private fun getElement(stackTrace: Array<StackTraceElement>, index: Int): StackTraceElement {
var i = index
if (stackTrace.size <= index) {
throw IllegalStateException(
"Synthetic stacktrace didn't have enough elements: are you using proguard?"
)
i = stackTrace.size - 1
//Log.e("L", "Synthetic stacktrace didn't have enough elements: are you using proguard?")
L.e { "Synthetic stacktrace didn't have enough elements: are you using proguard?" }
}
return stackTrace[index]
return stackTrace[i]
}

private fun getClassName(element: StackTraceElement?): String {
Expand Down

0 comments on commit 3be2248

Please sign in to comment.