Skip to content

Commit

Permalink
ReportDataWriter: default encoding pinned to UTF-8, not platform default
Browse files Browse the repository at this point in the history
UTF-8 is a long time documented default and more reliable.
  • Loading branch information
virgo47 committed Mar 15, 2023
1 parent ee904ac commit 63cd29d
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
/*
* Copyright (C) 2010-2022 Evolveum and contributors
* Copyright (C) 2010-2023 Evolveum and contributors
*
* This work is dual-licensed under the Apache License 2.0
* and European Union Public License. See LICENSE file for details.
*/
package com.evolveum.midpoint.report.impl.controller;

import java.nio.charset.Charset;
import java.nio.charset.StandardCharsets;
import java.util.function.Function;

import org.jetbrains.annotations.NotNull;
Expand Down Expand Up @@ -86,7 +87,6 @@ default Function<String, String> getFunctionForWidgetStatus() {
*/
@NotNull
default Charset getEncoding() {
return Charset.defaultCharset();
// return StandardCharsets.UTF_8; TODO wouldn't this be better? Definitely more predictable.
return StandardCharsets.UTF_8;
}
}

0 comments on commit 63cd29d

Please sign in to comment.