Replace many uses of to_ascii_lowercase() by make_ascii_lowercase()

This commit is contained in:
Anthony Ramine 2015-08-28 00:51:15 +02:00
parent 67cbda4be3
commit 105d990845
7 changed files with 32 additions and 23 deletions

View file

@ -489,7 +489,9 @@ impl HTMLScriptElement {
},
Some(ref s) => {
debug!("script language={}", *s);
SCRIPT_JS_MIMES.contains(&&*format!("text/{}", s).to_ascii_lowercase())
let mut language = format!("text/{}", s);
language.make_ascii_lowercase();
SCRIPT_JS_MIMES.contains(&&*language)
},
None => {
debug!("no script type or language, inferring js");