Просмотр исходного кода

Fix Url::from_file_path to be a static method.

Simon Sapin 12 лет назад
Родитель
Сommit
f1161aaaff
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      src/url.rs

+ 1 - 1
src/url.rs

@@ -193,7 +193,7 @@ impl Url {
 
     // FIXME: Figure out what to do on Windows
     #[cfg(unix)]
-    pub fn from_file_path(&self, path: &Path) -> Result<Url, ()> {
+    pub fn from_file_path(path: &Path) -> Result<Url, ()> {
         let path = try!(encode_file_path(path));
         Ok(Url {
             scheme: "file".to_string(),