Stop abusing format! macro when construct a String

In these cases for `format!`, we're just constructing a String of the
single argument with no special format.
This commit is contained in:
Corey Farwell 2015-03-22 18:54:56 -04:00
parent 445f1c891a
commit 5a780cb221
5 changed files with 7 additions and 7 deletions

View file

@ -1090,7 +1090,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
fn LastModified(self) -> DOMString {
match self.last_modified {
Some(ref t) => t.clone(),
None => format!("{}", time::now().strftime("%m/%d/%Y %H:%M:%S").unwrap()),
None => time::now().strftime("%m/%d/%Y %H:%M:%S").unwrap().to_string(),
}
}