aboutsummaryrefslogtreecommitdiff
path: root/parse_wiki_text
diff options
context:
space:
mode:
Diffstat (limited to 'parse_wiki_text')
-rw-r--r--parse_wiki_text/src/display.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/parse_wiki_text/src/display.rs b/parse_wiki_text/src/display.rs
index 4c1f03a..011dd40 100644
--- a/parse_wiki_text/src/display.rs
+++ b/parse_wiki_text/src/display.rs
@@ -32,7 +32,7 @@ impl std::fmt::Display for Node<'_> {
match name.get(0) {
Some(name) =>
if let Node::Text { value, .. } = name {
- write!(f, "{}", handle_template(*value, parameters)?)
+ write!(f, "{}", expand_template(*value, parameters)?)
} else {
Err(Error)
},
@@ -91,7 +91,7 @@ impl std::fmt::Display for Node<'_> {
// https://en.wiktionary.org/wiki/Wiktionary:Templates
// wow, a function entirely composed of edge cases
-fn handle_template(name: &str, parameters: &Vec<Parameter>) -> Result<String, Error> {
+fn expand_template(name: &str, parameters: &Vec<Parameter>) -> Result<String, Error> {
let mut buffer = String::from("");
match name {
"m" => {