commit | d9606defde4d8891eb5c858b98810248587c074c | [log] [tgz] |
---|---|---|
author | David Pursehouse <dpursehouse@collab.net> | Wed Apr 25 16:16:02 2018 +0900 |
committer | David Pursehouse <dpursehouse@collab.net> | Tue Nov 13 11:01:41 2018 -0800 |
tree | 5570637425dc0c6136e8d1154a3582a27f674b65 | |
parent | 6f6c43c6c48c5343adf226bc4d62b44fb04add50 [diff] |
Stop using deprecated Files.toString Replace with Files.asCharSource as recommended in the deprecation notice. Change-Id: Ib8491c1d63a2f1b2c5e8b5d9c28cdde220a43c49
diff --git a/src/main/java/com/criteo/gerrit/plugins/automerge/PluginComment.java b/src/main/java/com/criteo/gerrit/plugins/automerge/PluginComment.java index 4cacdd6..0ac8aff 100644 --- a/src/main/java/com/criteo/gerrit/plugins/automerge/PluginComment.java +++ b/src/main/java/com/criteo/gerrit/plugins/automerge/PluginComment.java
@@ -28,7 +28,7 @@ String getContent() { if (templatePath.exists()) { try { - return Files.toString(templatePath, Charsets.UTF_8); + return Files.asCharSource(templatePath, Charsets.UTF_8).read(); } catch (final IOException exc) { log.error("Not able to read " + templatePath, exc); }