Skip to content

Commit

Permalink
Fix export does append empty line
Browse files Browse the repository at this point in the history
  • Loading branch information
franksn90 committed May 15, 2024
1 parent aeaa6fb commit 5277682
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -79,11 +79,10 @@ class CSVFileExporter(private val monitoringCSVLoc: String, private val config:
writer: BufferedWriter
) {
writer.write(monitoringData.headers)
writer.newLine()
val endIndexInclusive = (endIndex + 1).coerceAtMost(monitoringData.data.size)
for (line in monitoringData.data.subList(startIndex, endIndexInclusive)) {
writer.write(line)
writer.newLine()
writer.write(line)
}
writer.close()
}
Expand Down

0 comments on commit 5277682

Please sign in to comment.