Skip to content

Commit

Permalink
Switch from ISO_8859_1 to UTF-8
Browse files Browse the repository at this point in the history
  • Loading branch information
iamgio committed Jan 2, 2019
1 parent 9ade1cd commit 7320ef3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/org/chorusmc/chorus/file/FTPFile.kt
Expand Up @@ -31,7 +31,7 @@ class FTPFile(private val connection: FTPRemoteConnection, private val path: Str
}

override val lines: List<String>
get() = IOUtils.toString(file, Charset.defaultCharset()).split("\n")
get() = IOUtils.toString(file, Charset.forName("UTF-8")).split("\n")

override val updatedFile: FileMethod?
get() = FTPFile(connection, path)
Expand Down
2 changes: 1 addition & 1 deletion src/org/chorusmc/chorus/file/LocalFile.kt
Expand Up @@ -20,7 +20,7 @@ class LocalFile(val file: File) : FileMethod {
get() = file.parentFile.name

override val lines: List<String>
get() = Files.readAllLines(file.toPath(), StandardCharsets.ISO_8859_1)
get() = Files.readAllLines(file.toPath(), StandardCharsets.UTF_8)

override val updatedFile: FileMethod?
get() = try {
Expand Down
2 changes: 1 addition & 1 deletion src/org/chorusmc/chorus/file/SFTPFile.kt
Expand Up @@ -28,7 +28,7 @@ class SFTPFile(private val connection: SFTPRemoteConnection, private val path: S
}

override val lines: List<String>
get() = IOUtils.toString(file, Charset.defaultCharset()).split("\n")
get() = IOUtils.toString(file, Charset.forName("UTF-8")).split("\n")

override val updatedFile: FileMethod?
get() = SFTPFile(connection, path)
Expand Down

0 comments on commit 7320ef3

Please sign in to comment.