diff options
| author | Owen Jacobson <owen@grimoire.ca> | 2024-10-25 00:33:16 -0400 |
|---|---|---|
| committer | Owen Jacobson <owen@grimoire.ca> | 2024-10-25 00:56:48 -0400 |
| commit | 5423ec3937a4e28f3958a71b3db7498a4c427dc1 (patch) | |
| tree | 8fc8531086c1691b0a9fc0a5ddb615d913dc6448 /src/ui/mime.rs | |
| parent | eae0edb57e9ade7c73affb78baf2ae267b6290b8 (diff) | |
Tests for purged channels and messages.
This required a re-think of the `.immediately()` combinator, to generalize it to cases where a message is _not_ expected. That (more or less immediately) suggested some mixed combinators, particularly for stream futures (futures of `Option<T>`).
Diffstat (limited to 'src/ui/mime.rs')
| -rw-r--r-- | src/ui/mime.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/ui/mime.rs b/src/ui/mime.rs index 9c724f0..7818ac1 100644 --- a/src/ui/mime.rs +++ b/src/ui/mime.rs @@ -1,7 +1,10 @@ use mime::Mime; use unix_path::Path; -// Extremely manual; using `std::path` here would result in platform-dependent behaviour when it's not appropriate (the URLs passed here always use `/` and are parsed like URLs). Using `unix_path` might be an option, but it's not clearly +// Extremely manual; using `std::path` here would result in platform-dependent +// behaviour when it's not appropriate (the URLs passed here always use `/` and +// are parsed like URLs). Using `unix_path` might be an option, but it's not +// clearly pub fn from_path<P>(path: P) -> Result<Mime, mime::FromStrError> where P: AsRef<Path>, |
