Ruby: improve wording of error messages

This commit is contained in:
Arthur Baars
2023-02-16 15:53:56 +01:00
parent 51f34eb3e9
commit 6fd836d3a9
3 changed files with 14 additions and 9 deletions

View File

@@ -203,8 +203,8 @@ fn main() -> std::io::Result<()> {
)
.file(&path.to_string_lossy())
.message(
"could not decode the file contents as {}: {}",
&[&encoding_name, &msg],
"Could not decode the file contents as {}: {}. Validate that the contents of the file matches the character encoding specified in the {} directive at the top of the file.",
&[&encoding_name, &msg, "encoding:"],
)
.status_page()
.severity(diagnostics::Severity::Warning),
@@ -218,7 +218,7 @@ fn main() -> std::io::Result<()> {
.new_entry("unknown-character-encoding", "Unknown character encoding")
.file(&path.to_string_lossy())
.message(
"unknown character encoding {} in {} directive.",
"Unknown character encoding {} in {} directive. Validate that the specified name is a supported character set.",
&[&encoding_name, "#encoding:"],
)
.status_page()