Skip to content

Commit

Permalink
More comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Stephen Moyer committed Jun 11, 2020
1 parent 4608a63 commit 1c413ef
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/Serilog.Sinks.Loki/LokiBatchFormatter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ public void Format(IEnumerable<LogEvent> logEvents, ITextFormatter formatter, Te

// Loki doesn't like \r\n for new line, and we can't guarantee the message doesn't have any
// in it, so we replace \r\n with \n on the final message
// We also flip backslashes to forward slashes, Loki doesn't like those either.
stream.Entries.Add(new LokiEntry(time, sb.ToString().Replace("\\", "/").Replace("\r\n", "\n")));
}

Expand Down

0 comments on commit 1c413ef

Please sign in to comment.