From fb484212f33f04e544833b297d8f84af3962b502 Mon Sep 17 00:00:00 2001 From: Stian Gustavsson Date: Mon, 25 Nov 2024 11:22:02 +0100 Subject: [PATCH] Update TestnavLogbackEncoder.java Fix for ident formatMessage --- .../libs/reactivecore/logging/TestnavLogbackEncoder.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libs/reactive-core/src/main/java/no/nav/testnav/libs/reactivecore/logging/TestnavLogbackEncoder.java b/libs/reactive-core/src/main/java/no/nav/testnav/libs/reactivecore/logging/TestnavLogbackEncoder.java index 3f43eac0b06..ebaf3ca809d 100644 --- a/libs/reactive-core/src/main/java/no/nav/testnav/libs/reactivecore/logging/TestnavLogbackEncoder.java +++ b/libs/reactive-core/src/main/java/no/nav/testnav/libs/reactivecore/logging/TestnavLogbackEncoder.java @@ -114,7 +114,7 @@ private void appendStackTraceCauses(ThrowableProxy exception, StringWriter write private String formatMessage(String message) { message = identNummer.matcher(message).replaceAll(match -> { - if (match.group().charAt(2) == '0' || match.group().charAt(2) == '1') { + if (match.group().charAt(2) < '4') { return match.group().substring(0, 6) + "xxxxx"; } return match.group(); @@ -124,4 +124,4 @@ private String formatMessage(String message) { return message; } -} \ No newline at end of file +}